Skip to content

Commit

Permalink
Add CR
Browse files Browse the repository at this point in the history
  • Loading branch information
mshinwell committed Dec 12, 2024
1 parent 115d4cf commit 5dabde8
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions middle_end/flambda2/from_lambda/lambda_to_lambda_transforms.ml
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,20 @@ let makearray_dynamic_non_scannable_unboxed_product env
(* Note that we don't check the number of unarized arguments against the
layout; we trust the front end. If we wanted to do this, it would have to
be done slightly later, after unarization. *)
(* CR mshinwell: two things were tried here, but one is dirty and the other
needed too much work:
- CPS convert the primitive arguments before getting here. They may then
have to be converted a second time, in the event that the primitive is
transformed by this file.
- For this primitive only, have a function passed in here which when
called, does the CPS conversion of the arguments and then escapes using an
exception, returning the number of arguments. This seems dirty.
Both of these cases introduce complexity as it is necessary to go back to
using an older accumulator during CPS conversion. This is probably fine but
is a real change. *)
let term =
L.(
Lprim
Expand Down

0 comments on commit 5dabde8

Please sign in to comment.