History

x86-64 codegen: avoid allocating VLA of size 0

Pascal Cuoq committed 7 years ago

Commit 944fe701 parent d39c49d1 file · +1 −1Browse files

Unified · Split

x86_64-gen.c+1−1
@@ -1234,7 +1234,7 @@ void gfunc_call(int nb_args) · 1233 unmodified lines
1234 int nb_reg_args = 0;1234 int nb_reg_args = 0;
1235 int nb_sse_args = 0;1235 int nb_sse_args = 0;
1236 int sse_reg, gen_reg;1236 int sse_reg, gen_reg;
1237 char _onstack[nb_args], *onstack = _onstack;1237 char _onstack[nb_args ? nb_args : 1], *onstack = _onstack;
1238 1238
1239 /* calculate the number of integer/float register arguments, remember1239 /* calculate the number of integer/float register arguments, remember
1240 arguments to be passed via stack (in onstack[]), and also remember1240 arguments to be passed via stack (in onstack[]), and also remember

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t