Skip to content

Better half

Daniel Campora Perez requested to merge dcampora_allen_tdr_half_cleanup into allen_tdr

This MR adds an option to compile with CPU: CPU_USE_REAL_HALF. Toggling it makes the CPU build switch between uint16_t and float for its backend datatype for half_t.

In addition, the UT event model has been cleaned up. ut pre decode now uses dev_ut_pre_decoded_hits_t for its output datatype. This allows making UT::Hits_t a single purpose type, and enables UT::Consolidated::Hits_t to inherit from UT::Hits_t, simplifying UT datatypes.

  • The intrinsics instructions _mm_cvtps_ph and _mm_cvtph_ps are used if: the code was compiled with __F16C__ (ie. -march=ivybridge enables this), and if the CPU has the capability to run it (checked at runtime).
  • By default, CPU_USE_REAL_HALF is turned off. Note that the result doesn't change if it is turned on, since the conversion is done nevertheless.
Edited by Daniel Campora Perez

Merge request reports