You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
remove_labels init_clock c pos labs ffis sec_list =
(* Here init_clock puts an upper limit on the number of times the
lengths can be adjusted. In many cases, clock = 0 should be
enough. If this were to hit the clock limit for large values of
init_clock, then something is badly wrong. Worth testing with
the clock limit set to low values to see how many iterations
are used. *)
remove_labels_loop init_clock c pos labs ffis (enc_sec_list c.encode sec_list)`;
This function should not be recursive and should not use a clock.
To remove the clock, one needs to assume that the length of encodings of Loc and Jump are independent of the label/jump offset. Concretely, enc_ok_def should change:
Could you sketch how the offset_monotonic condition should be used in lab_to_target?
From what I'm reading, isn't it still possible that the length of a Jump/Loc instruction could increase when w1 increases to w2 and that could require another loop around in remove_labels?
Currently the
lab_to_target
pass contains a recursive functions with a clock that can signal that the compiler should give up.cakeml/compiler/backend/lab_to_targetScript.sml
Lines 236 to 244 in 40f98ca
This function should not be recursive and should not use a clock.
To remove the clock, one needs to assume that the length of encodings of
Loc
andJump
are independent of the label/jump offset. Concretely,enc_ok_def
should change:cakeml/compiler/encoders/asm/asmPropsScript.sml
Lines 25 to 43 in 40f98ca
and the implementation and verification of
remove_labels
should make use of the change.The text was updated successfully, but these errors were encountered: