diff options
| author | Alasdair Armstrong | 2018-08-29 18:01:50 +0100 |
|---|---|---|
| committer | Alasdair Armstrong | 2018-08-29 18:35:50 +0100 |
| commit | a5ad2059821b86ef26a86d78c40cc680c57aa94e (patch) | |
| tree | 468eb6bb76f995fb24872e028b0f7a9c7af8f06a /lib | |
| parent | 07e3591e2427db2d9407d554ac57984ca566c6ed (diff) | |
C: Fix some issues with tuples as arguments to polymorphic constructors
Now all we need to do is make sure the RISC-V builtins are mapped to
the correct C functions, and RISC-V in C should work
(hopefully). We're still missing some of the functions in sail.c for
the mappings so those have to be implemented.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/sail.c | 7 | ||||
| -rw-r--r-- | lib/sail.h | 3 |
2 files changed, 8 insertions, 2 deletions
@@ -1068,7 +1068,12 @@ void string_of_int(sail_string *str, const sail_int i) gmp_asprintf(str, "%Zd", i); } -void string_of_bits(sail_string *str, const sail_bits op) +void string_of_mach_bits(sail_string *str, const mach_bits op) +{ + exit(EXIT_FAILURE); +} + +void string_of_sail_bits(sail_string *str, const sail_bits op) { if ((op.len % 4) == 0) { gmp_asprintf(str, "0x%*0Zx", op.len / 4, *op.bits); @@ -320,7 +320,8 @@ void random_real(real *rop, unit); /* ***** Printing ***** */ void string_of_int(sail_string *str, const sail_int i); -void string_of_bits(sail_string *str, const sail_bits op); +void string_of_sail_bits(sail_string *str, const sail_bits op); +void string_of_mach_bits(sail_string *str, const mach_bits op); /* * Utility function not callable from Sail! |
