summaryrefslogtreecommitdiff
path: root/testsuite/tests/cps/cps015.cmm
blob: 2068dd80c32cc452ea641a17130100d0b5b71d0f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// Test whether a stack check is performed even when
// the existing stack due to on-stack arguments is big enough.

// With space for a return address
foo1 (bits32 x, bits32 y) goto GC {
  foreign "C--" bar(x) "safe";
  return (1);
GC:
  return (1);
}

// No space needed for a return address
foo2 (bits32 x, bits32 y) goto GC {
  jump bar(x, y);
GC:
  return (1);
}