Skip to content

Commit b335cbe

Browse files
committed
Memoize linux check
It is done inside a loop
1 parent 51e532c commit b335cbe

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/benchmark_suite.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ def benchmark_ractor_directory?
166166

167167
# Check if running on Linux
168168
def linux?
169-
RbConfig::CONFIG['host_os'] =~ /linux/
169+
@linux ||= RbConfig::CONFIG['host_os'] =~ /linux/
170170
end
171171

172172
# Generate setarch prefix for Linux

0 commit comments

Comments
 (0)