Skip to content

Commit a36d209

Browse files
committed
[SYCL] Don't reject devices from default selector
1 parent 5d91dec commit a36d209

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

sycl/source/device_selector.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,8 @@ device device_selector::select_device() const {
113113
/// 3. Host
114114
/// 4. Accelerator
115115
int default_selector::operator()(const device &dev) const {
116-
int Score = REJECT_DEVICE_SCORE;
116+
// The default selector doesn't reject any devices.
117+
int Score = 0;
117118

118119
if (dev.get_info<info::device::device_type>() == detail::get_forced_type())
119120
Score += 2000;
@@ -133,9 +134,8 @@ int default_selector::operator()(const device &dev) const {
133134
if (dev.is_accelerator())
134135
Score += 75;
135136

136-
// If the device wasn't rejected, add preference score.
137-
if (Score > REJECT_DEVICE_SCORE)
138-
Score += getDevicePreference(dev);
137+
// Add preference score.
138+
Score += getDevicePreference(dev);
139139

140140
return Score;
141141
}

0 commit comments

Comments
 (0)