path: root/VERSION
diff options
authorMarcin Ślusarz <>2021-10-13 11:21:41 +0200
committerMarge Bot <>2021-10-27 23:51:47 +0000
commitf1926fed4a4a3d112787d08eac7a82dc8cfd97ed (patch)
treecce46d6c29aac01fbd296f3a7d132f24a68dbfbe /VERSION
parent702b0c31bd9de67cf40c19f7fc54fece6352e68b (diff)
intel: fix INTEL_DEBUG environment variable on 32-bit systems
INTEL_DEBUG is defined (since 4015e1876a77162e3444eeaa29a0dfbc47efe90e) as: #define INTEL_DEBUG __builtin_expect(intel_debug, 0) which unfortunately chops off upper 32 bits from intel_debug on platforms where sizeof(long) != sizeof(uint64_t) because __builtin_expect is defined only for the long type. Fix this by changing the definition of INTEL_DEBUG to be function-like macro with "flags" argument. New definition returns 0 or 1 when any of the flags match. Most of the changes in this commit were generated using: for c in `git grep INTEL_DEBUG | grep "&" | grep -v i915 | awk -F: '{print $1}' | sort | uniq`; do perl -pi -e "s/INTEL_DEBUG & ([A-Z0-9a-z_]+)/INTEL_DBG(\1)/" $c perl -pi -e "s/INTEL_DEBUG & (\([A-Z0-9_ |]+\))/INTEL_DBG\1/" $c done but it didn't handle all cases and required minor cleanups (like removal of round brackets which were not needed anymore). Signed-off-by: Marcin Ślusarz <> Reviewed-by: Kenneth Graunke <> Reviewed-by: Caio Marcelo de Oliveira Filho <> Part-of: <>
Diffstat (limited to 'VERSION')
0 files changed, 0 insertions, 0 deletions