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
val rem_round_zero = {ocaml: "rem_round_zero", interpreter: "rem_round_zero", lem: "hardware_mod", c: "tmod_int", coq: "Z.rem"} : (int, int) -> int
Might it not be better to just have something like
extern val rem_round_zero : (int, int) -> int
And then the names actually used for each backend are constructed by convention. E.g. OCaml gets SailExtern.$name, C gets sail_extern_$name, interpreter gets $name (or sail_extern_$name?, etc.
It's a little bit more "magical" and less greppable/discoverable. But it means the Sail code doesn't have to care about a list of backends any more.
The text was updated successfully, but these errors were encountered:
This would be nice, but I'm not sure how easy it would be to go back and clean everything up to make this work without causing a lot of backwards-compatibility headaches.
We do also allow:
val f : {c: "some_fast_implementation"} : T
// slow Sail implementation for other backends
function f() = ...
which would be a bit harder with this simpler scheme.
I was thinking... instead of this:
Might it not be better to just have something like
And then the names actually used for each backend are constructed by convention. E.g. OCaml gets
SailExtern.$name
, C getssail_extern_$name
, interpreter gets$name
(orsail_extern_$name
?, etc.It's a little bit more "magical" and less greppable/discoverable. But it means the Sail code doesn't have to care about a list of backends any more.
The text was updated successfully, but these errors were encountered: