Skip to content

Commit 1762fee

Browse files
committed
Drop SSE2 backend
1 parent 173af65 commit 1762fee

File tree

10 files changed

+70
-184
lines changed

10 files changed

+70
-184
lines changed

.gitea/workflows/release.yml

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -580,30 +580,30 @@ jobs:
580580
# with:
581581
# name: macos-x86_64-cpu-output
582582
# path: macos-x86_64-cpu-output/
583-
test-linux-x86_64-cpu-sse2:
584-
runs-on: [ linux, x86_64 ]
585-
needs:
586-
- build-linux-x86_64-rel
587-
steps:
588-
- name: Checkout Workflows
589-
uses: actions/checkout@v4
590-
with:
591-
sparse-checkout: .gitea
592-
- name: Re-initialize repository
593-
uses: ./.gitea/actions/checkout
594-
- name: Run Tests
595-
uses: ./.gitea/actions/test-sde
596-
with:
597-
bin-dir: "linux-x86_64"
598-
out-dir: "linux-x86_64-cpu-sse2-output"
599-
test-args: "--arch SSE2 --nogpu -j4"
600-
sde-args: "-p4p"
601-
- name: Upload artifacts
602-
uses: actions/upload-artifact@v3
603-
if: always()
604-
with:
605-
name: linux-x86_64-cpu-sse2-output
606-
path: linux-x86_64-cpu-sse2-output/
583+
# test-linux-x86_64-cpu-sse2:
584+
# runs-on: [ linux, x86_64 ]
585+
# needs:
586+
# - build-linux-x86_64-rel
587+
# steps:
588+
# - name: Checkout Workflows
589+
# uses: actions/checkout@v4
590+
# with:
591+
# sparse-checkout: .gitea
592+
# - name: Re-initialize repository
593+
# uses: ./.gitea/actions/checkout
594+
# - name: Run Tests
595+
# uses: ./.gitea/actions/test-sde
596+
# with:
597+
# bin-dir: "linux-x86_64"
598+
# out-dir: "linux-x86_64-cpu-sse2-output"
599+
# test-args: "--arch SSE2 --nogpu -j4"
600+
# sde-args: "-p4p"
601+
# - name: Upload artifacts
602+
# uses: actions/upload-artifact@v3
603+
# if: always()
604+
# with:
605+
# name: linux-x86_64-cpu-sse2-output
606+
# path: linux-x86_64-cpu-sse2-output/
607607
test-linux-x86_64-cpu-sse41:
608608
runs-on: [ linux, x86_64 ]
609609
needs:
@@ -820,7 +820,7 @@ jobs:
820820
# path: windows-arm64-gpu-perf-output/
821821
analyze-output:
822822
runs-on: [ linux ]
823-
needs: [ test-windows-x86_64-cpu, test-windows-x86_64-gpu-amd, test-windows-x86_64-gpu-uhd, test-windows-x86_64-gpu-arc, test-linux-x86_64-cpu, test-linux-x86_64-gpu-nv, test-linux-x86_64-cpu-sse2, test-linux-x86_64-cpu-sse41, test-windows-x86_64-cpu-avx, test-windows-x86_64-cpu-avx2, test-windows-x86_64-cpu-avx512, test-linux-x86_64-cpu-tsan, test-windows-x86_64-cpu-asan, test-windows-x86_64-gpu-amd-asan ]
823+
needs: [ test-windows-x86_64-cpu, test-windows-x86_64-gpu-amd, test-windows-x86_64-gpu-uhd, test-windows-x86_64-gpu-arc, test-linux-x86_64-cpu, test-linux-x86_64-gpu-nv, test-linux-x86_64-cpu-sse41, test-windows-x86_64-cpu-avx, test-windows-x86_64-cpu-avx2, test-windows-x86_64-cpu-avx512, test-linux-x86_64-cpu-tsan, test-windows-x86_64-cpu-asan, test-windows-x86_64-gpu-amd-asan ]
824824
if: always()
825825
steps:
826826
- name: Checkout Workflows
@@ -879,10 +879,10 @@ jobs:
879879
# with:
880880
# name: macos-x86_64-cpu-output
881881
# path: macos-x86_64-cpu-output/
882-
- uses: actions/download-artifact@v3
883-
with:
884-
name: linux-x86_64-cpu-sse2-output
885-
path: linux-x86_64-cpu-sse2-output/
882+
# - uses: actions/download-artifact@v3
883+
# with:
884+
# name: linux-x86_64-cpu-sse2-output
885+
# path: linux-x86_64-cpu-sse2-output/
886886
- uses: actions/download-artifact@v3
887887
with:
888888
name: linux-x86_64-cpu-sse41-output
@@ -921,5 +921,5 @@ jobs:
921921
# path: windows-arm64-gpu-perf-output/
922922
- name: Analyze Output
923923
run: |
924-
python scripts/analyze_output.py windows-x86_64-cpu-output/test_Ray_output.txt windows-x86_64-gpu-amd-output/test_Ray_output.txt windows-x86_64-gpu-uhd-output/test_Ray_output.txt windows-x86_64-gpu-arc-output/test_Ray_output.txt linux-x86_64-cpu-output/test_Ray_output.txt linux-x86_64-gpu-nv-output/test_Ray_output.txt linux-x86_64-cpu-sse2-output/test_Ray_output.txt linux-x86_64-cpu-sse41-output/test_Ray_output.txt windows-x86_64-cpu-avx-output/test_Ray_output.txt windows-x86_64-cpu-avx2-output/test_Ray_output.txt windows-x86_64-cpu-avx512-output/test_Ray_output.txt linux-x86_64-cpu-tsan-output/test_Ray_output.txt windows-x86_64-cpu-asan-output/test_Ray_output.txt windows-x86_64-gpu-amd-asan-output/test_Ray_output.txt
924+
python scripts/analyze_output.py windows-x86_64-cpu-output/test_Ray_output.txt windows-x86_64-gpu-amd-output/test_Ray_output.txt windows-x86_64-gpu-uhd-output/test_Ray_output.txt windows-x86_64-gpu-arc-output/test_Ray_output.txt linux-x86_64-cpu-output/test_Ray_output.txt linux-x86_64-gpu-nv-output/test_Ray_output.txt linux-x86_64-cpu-sse41-output/test_Ray_output.txt windows-x86_64-cpu-avx-output/test_Ray_output.txt windows-x86_64-cpu-avx2-output/test_Ray_output.txt windows-x86_64-cpu-avx512-output/test_Ray_output.txt linux-x86_64-cpu-tsan-output/test_Ray_output.txt windows-x86_64-cpu-asan-output/test_Ray_output.txt windows-x86_64-gpu-amd-asan-output/test_Ray_output.txt
925925
shell: bash

CMakeLists.txt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -134,8 +134,6 @@ endif()
134134

135135
if (ENABLE_SIMD_IMPL)
136136
set(INTERNAL_SOURCE_FILES ${INTERNAL_SOURCE_FILES}
137-
internal/RendererSSE2.h
138-
internal/RendererSSE2.cpp
139137
internal/RendererSSE41.h
140138
internal/RendererSSE41.cpp
141139
internal/RendererNEON.h
@@ -148,7 +146,6 @@ if (ENABLE_SIMD_IMPL)
148146
internal/RendererAVX512.cpp)
149147

150148
set_source_files_properties(
151-
internal/RendererSSE2.cpp
152149
internal/RendererSSE41.cpp
153150
internal/RendererNEON.cpp
154151
internal/RendererAVX.cpp
@@ -184,7 +181,6 @@ endif(ENABLE_DX_IMPL AND WIN32)
184181
if(NOT CMAKE_GENERATOR_PLATFORM MATCHES "ARM64")
185182
if(MSVC)
186183
if(NOT CMAKE_CL_64)
187-
set_source_files_properties(internal/RendererSSE2.cpp PROPERTIES COMPILE_FLAGS /arch:SSE2)
188184
set_source_files_properties(internal/TextureUtilsSSE2.cpp PROPERTIES COMPILE_FLAGS /arch:SSE2)
189185
set_source_files_properties(internal/RendererSSE41.cpp PROPERTIES COMPILE_FLAGS /arch:SSE2)
190186
endif()
@@ -198,7 +194,6 @@ if(NOT CMAKE_GENERATOR_PLATFORM MATCHES "ARM64")
198194
else()
199195
set_source_files_properties(internal/simd/detect.cpp PROPERTIES COMPILE_FLAGS -mxsave)
200196
set_source_files_properties(internal/TextureUtilsSSE2.cpp PROPERTIES COMPILE_FLAGS -msse2)
201-
set_source_files_properties(internal/RendererSSE2.cpp PROPERTIES COMPILE_FLAGS -msse2)
202197
set_source_files_properties(internal/RendererSSE41.cpp PROPERTIES COMPILE_FLAGS -msse4.1)
203198
set_source_files_properties(internal/RendererAVX.cpp PROPERTIES COMPILE_FLAGS -mavx)
204199
set_source_files_properties(internal/RendererAVX2.cpp PROPERTIES COMPILE_FLAGS "-mavx2 -mfma")

Ray.cpp

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,11 @@
1515
#include "internal/RendererAVX.h"
1616
#include "internal/RendererAVX2.h"
1717
#include "internal/RendererAVX512.h"
18-
#include "internal/RendererSSE2.h"
1918
#include "internal/RendererSSE41.h"
2019
#elif defined(__arm__) || defined(__aarch64__) || defined(_M_ARM) || defined(_M_ARM64)
2120
#include "internal/RendererNEON.h"
2221
#elif defined(__i386__) || defined(__x86_64__)
23-
#include "internal/RendererSSE2.h"
22+
#include "internal/RendererSSE41.h"
2423
#endif
2524
#else // ENABLE_SIMD_IMPL
2625
#pragma message("Ray: Compiling without SIMD support")
@@ -93,10 +92,6 @@ Ray::RendererBase *Ray::CreateRenderer(const settings_t &s, ILog *log,
9392
log->Info("Ray: Creating SSE41 renderer %ix%i", s.w, s.h);
9493
return Sse41::CreateRenderer(s, log);
9594
}
96-
if ((enabled_types & eRendererType::SIMD_SSE2) && features.sse2_supported) {
97-
log->Info("Ray: Creating SSE2 renderer %ix%i", s.w, s.h);
98-
return Sse2::CreateRenderer(s, log);
99-
}
10095
#endif
10196
#ifdef ENABLE_REF_IMPL
10297
if (enabled_types & eRendererType::Reference) {

Ray.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ extern LogStdout g_stdout_log;
1616

1717
/// Default renderer flags used to choose backend, by default tries to create gpu renderer first
1818
const Bitmask<eRendererType> DefaultEnabledRenderTypes =
19-
Bitmask<eRendererType>{eRendererType::Reference} | eRendererType::SIMD_SSE2 | eRendererType::SIMD_AVX |
19+
Bitmask<eRendererType>{eRendererType::Reference} | eRendererType::SIMD_SSE41 | eRendererType::SIMD_AVX |
2020
eRendererType::SIMD_AVX2 | eRendererType::SIMD_NEON | eRendererType::Vulkan | eRendererType::DirectX12;
2121

2222
/** @brief Creates renderer

RendererBase.cpp

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ std::string_view RendererTypeName(const eRendererType rt) {
77
switch (rt) {
88
case eRendererType::Reference:
99
return "REF";
10-
case eRendererType::SIMD_SSE2:
11-
return "SSE2";
1210
case eRendererType::SIMD_SSE41:
1311
return "SSE41";
1412
case eRendererType::SIMD_AVX:
@@ -31,8 +29,6 @@ std::string_view RendererTypeName(const eRendererType rt) {
3129
eRendererType RendererTypeFromName(std::string_view name) {
3230
if (name == "REF") {
3331
return eRendererType::Reference;
34-
} else if (name == "SSE2") {
35-
return eRendererType::SIMD_SSE2;
3632
} else if (name == "SSE41") {
3733
return eRendererType::SIMD_SSE41;
3834
} else if (name == "AVX") {
@@ -54,7 +50,6 @@ eRendererType RendererTypeFromName(std::string_view name) {
5450
bool RendererSupportsMultithreading(const eRendererType rt) {
5551
switch (rt) {
5652
case eRendererType::Reference:
57-
case eRendererType::SIMD_SSE2:
5853
case eRendererType::SIMD_SSE41:
5954
case eRendererType::SIMD_AVX:
6055
case eRendererType::SIMD_AVX2:

RendererBase.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ enum class eRendererType : uint32_t {
2323
// Reference CPU renderer, slightly vectorized, the easiest to modify and debug
2424
Reference,
2525
// SIMD CPU renderers, heavily vectorized in SPMD fashion
26-
SIMD_SSE2,
2726
SIMD_SSE41,
2827
SIMD_AVX,
2928
SIMD_AVX2,
@@ -35,7 +34,7 @@ enum class eRendererType : uint32_t {
3534
};
3635

3736
// All CPU renderers
38-
const Bitmask<eRendererType> RendererCPU = Bitmask<eRendererType>{eRendererType::Reference} | eRendererType::SIMD_SSE2 |
37+
const Bitmask<eRendererType> RendererCPU = Bitmask<eRendererType>{eRendererType::Reference} |
3938
eRendererType::SIMD_SSE41 | eRendererType::SIMD_NEON |
4039
eRendererType::SIMD_AVX | eRendererType::SIMD_AVX2;
4140
// All GPU renderers

internal/RendererSSE2.cpp

Lines changed: 0 additions & 85 deletions
This file was deleted.

internal/RendererSSE2.h

Lines changed: 0 additions & 14 deletions
This file was deleted.

tests/main.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ bool g_stop_on_fail = false;
121121
std::atomic_bool g_tests_success{true};
122122
std::atomic_bool g_log_contains_errors{false};
123123
bool g_catch_flt_exceptions = false;
124-
bool g_determine_sample_count = false;
124+
bool g_determine_sample_count = true;
125125
bool g_minimal_output = false;
126126
bool g_nohwrt = false;
127127
bool g_nodx = false;
@@ -227,8 +227,8 @@ int main(int argc, char *argv[]) {
227227
}
228228
#endif
229229

230-
static const char *ArchListFull[] = {"REF", "SSE2", "SSE41", "AVX", "AVX2", "AVX512", "NEON", "VK", "DX", nullptr};
231-
static const char *ArchListFullNoGPU[] = {"REF", "SSE2", "SSE41", "AVX", "AVX2", "AVX512", "NEON", nullptr};
230+
static const char *ArchListFull[] = {"REF", "SSE41", "AVX", "AVX2", "AVX512", "NEON", "VK", "DX", nullptr};
231+
static const char *ArchListFullNoGPU[] = {"REF", "SSE41", "AVX", "AVX2", "AVX512", "NEON", nullptr};
232232
static const char *ArchListDefault[] = {"AVX2", "NEON", "VK", "DX", nullptr};
233233
#ifndef __APPLE__
234234
static const char *ArchListDefaultNoGPU[] = {"AVX2", "NEON", nullptr};

0 commit comments

Comments
 (0)