diff options
author | David Monniaux <david.monniaux@univ-grenoble-alpes.fr> | 2019-05-15 17:08:11 +0200 |
---|---|---|
committer | David Monniaux <david.monniaux@univ-grenoble-alpes.fr> | 2019-05-15 17:08:11 +0200 |
commit | bf58adcc2f4d73d55cbc90f6eff0f96fe7d30c45 (patch) | |
tree | 51ea831d5eb0a3107f8f8d281f4ea9709422a412 | |
parent | f72612aed2b9ec147b5e60a53c9e13b94aa71cdb (diff) | |
download | compcert-kvx-bf58adcc2f4d73d55cbc90f6eff0f96fe7d30c45.tar.gz compcert-kvx-bf58adcc2f4d73d55cbc90f6eff0f96fe7d30c45.zip |
truly inline function as macro to trigger better instruction selection
(replace x/2 by x*0.5)
-rw-r--r-- | test/monniaux/lustrev4_lv6-en-2cgc_heater_control/heater_control_heater_control.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/test/monniaux/lustrev4_lv6-en-2cgc_heater_control/heater_control_heater_control.c b/test/monniaux/lustrev4_lv6-en-2cgc_heater_control/heater_control_heater_control.c index b850598a..b3995c61 100644 --- a/test/monniaux/lustrev4_lv6-en-2cgc_heater_control/heater_control_heater_control.c +++ b/test/monniaux/lustrev4_lv6-en-2cgc_heater_control/heater_control_heater_control.c @@ -45,10 +45,15 @@ DM_INLINE void Lustre_pre_set(_boolean i1,Lustre_pre_ctx_type* ctx){ } // End of Lustre_pre_set // Step function(s) for Lustre_slash_ctx +#if 0 DM_INLINE void Lustre_slash_step(_real i1,_real i2,_real *out){ *out = (i1 / i2); -} // End of Lustre_slash_step +} +#else +#define Lustre_slash_step(x, y, out) *out = x/y +#endif +// End of Lustre_slash_step // Memory initialisation for heater_control_heater_control_ctx DM_INLINE void heater_control_heater_control_ctx_reset(heater_control_heater_control_ctx_type* ctx){ |