Changes between Version 142 and Version 143 of IR
- Timestamp:
- 02/04/16 14:38:02 (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
IR
v142 v143 327 327 * `WAITALL e, n;` : wait on all procs in a list 328 328 * `e` has type `Pointer[Proc]` and `n` has an integral type, the number of procs in the list 329 * `ALLOCATE e, h, t, e0;`329 * `ALLOCATE e, s, t, e0;` 330 330 * `e` has static type `Pointer[T]`, for some static type `T` 331 * ` h` has type `Heap`331 * `s` has type `Scope` 332 332 * `t` has type `Dytype[T]`, for the same static type `T` 333 333 * `e0` has an integral type. 334 * Allocates `e0` objects of type `t` on heap `h`, returning pointer to first element in `e`. 335 * **WOULD IT BE BETTER TO SPECIFY THE SCOPE?** 334 * Allocates `e0` objects of type `t` on the heap of `s`, returning pointer to first element in `e`. 336 335 * To translate the C `malloc` you first need to figure out the type of the elements being malloced. If the argument to malloc is `n`, then you first need to insert an assertion `eq(mod(n, sizeof_type(t)), 0)`, and then `ALLOCATE e, h, t, div(n, sizeof_type(t))`. 337 336 * `FREE p;`
