summaryrefslogtreecommitdiff
path: root/src/cmd/5c/cgen.c
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2013-07-16 16:24:43 -0400
committerRuss Cox <rsc@golang.org>2013-07-16 16:24:43 -0400
commitd509fcb571316971fe8cf1ade6f12744b8dec8b4 (patch)
tree1c7d5623daa1e1ef382a936df2720a921276028e /src/cmd/5c/cgen.c
parentc71f0e458019672a66932e70d20d2604cfaa23f5 (diff)
downloadgo-d509fcb571316971fe8cf1ade6f12744b8dec8b4.tar.gz
cmd/5c, cmd/6c, cmd/8c: record arg size for every call
R=ken2 CC=golang-dev https://codereview.appspot.com/11364043
Diffstat (limited to 'src/cmd/5c/cgen.c')
-rw-r--r--src/cmd/5c/cgen.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/cmd/5c/cgen.c b/src/cmd/5c/cgen.c
index 5ff4f633d..08ed36055 100644
--- a/src/cmd/5c/cgen.c
+++ b/src/cmd/5c/cgen.c
@@ -28,8 +28,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
-
#include "gc.h"
+#include "../../pkg/runtime/funcdata.h"
void
_cgen(Node *n, Node *nn, int inrel)
@@ -366,12 +366,14 @@ _cgen(Node *n, Node *nn, int inrel)
if(REGARG >= 0)
o = reg[REGARG];
gargs(r, &nod, &nod1);
+ gpcdata(PCDATA_ArgSize, curarg);
if(l->addable < INDEXED) {
reglcgen(&nod, l, Z);
gopcode(OFUNC, Z, Z, &nod);
regfree(&nod);
} else
gopcode(OFUNC, Z, Z, l);
+ gpcdata(PCDATA_ArgSize, -1);
if(REGARG >= 0)
if(o != reg[REGARG])
reg[REGARG]--;