diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 04bcb7c9d5..5b7cc33fa6 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -535,6 +535,8 @@ jobs: test/test_tiny.py test/test_rangeify.py test/test_ops.py test/test_symbolic_ops.py test/test_symbolic_jit.py test/test_tensor_variable.py \ test/test_outerworld_range.py test/test_randomness.py test/test_nn.py test/test_arange.py test/test_tensor.py test/test_optim.py \ test/test_setitem.py test/test_assign.py test/test_multitensor.py + - name: Test CPU=1 DEVECTORIZE=0 (RANGEIFY=1) + run: CPU=1 CPU_LLVM=0 RANGEIFY=1 DEVECTORIZE=0 FUSE_ARANGE=0 python3 -m pytest -n auto test/test_tiny.py test/test_ops.py -k "not test_avg_pool3d_failure" - name: Test CPU=1 CPU_LLVM=1 RANGEIFY=1 run: | CPU=1 CPU_LLVM=1 RANGEIFY=1 python3 -m pytest -n auto --durations 20 test/test_edgecases.py diff --git a/tinygrad/renderer/cstyle.py b/tinygrad/renderer/cstyle.py index 09d25c0828..3377e17905 100644 --- a/tinygrad/renderer/cstyle.py +++ b/tinygrad/renderer/cstyle.py @@ -215,8 +215,8 @@ class ClangRenderer(CStyleLanguage): kernel_typedef = "__attribute__((ms_abi)) void" def render_vector_prefix(self, dt:DType) -> str: # round (down) to power of two (this is actually the default clang behavior) - alignment = 2**int(math.log2(dt.itemsize)) if getenv("ALIGNED", 1) else 1 - return f"typedef {self.render_dtype(dt.scalar())} {self.render_dtype(dt)} __attribute__((aligned({alignment}),vector_size({dt.itemsize})));" + alignment = 2**int(math.log2(dt.itemsize)) if getenv("ALIGNED", 1) and not dtypes.is_bool(dt) else 1 + return f"typedef {self.render_dtype(dt.scalar())} {self.render_dtype(dt)} __attribute__((aligned({alignment}),ext_vector_type({dt.count})));" def _render_defines(self, uops) -> list[str]: prefix = [self.render_vector_prefix(dt) for dt in uops_to_dtypes(uops) if dt.count > 1]