Skip to content

Commit 42f9545

Browse files
committed
Remove VM lock for sym_find
1 parent 2235fdb commit 42f9545

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

symbol.c

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -827,12 +827,10 @@ sym_find(VALUE str)
827827
{
828828
VALUE sym;
829829

830-
GLOBAL_SYMBOLS_LOCKING(symbols) {
831-
struct sym_set_static_sym_entry static_sym = {
832-
.str = str
833-
};
834-
sym = rb_concurrent_set_find(&symbols->sym_set, sym_set_static_sym_tag(&static_sym));
835-
}
830+
struct sym_set_static_sym_entry static_sym = {
831+
.str = str
832+
};
833+
sym = rb_concurrent_set_find(&ruby_global_symbols.sym_set, sym_set_static_sym_tag(&static_sym));
836834

837835
if (sym) {
838836
return sym_set_entry_to_sym(sym);

0 commit comments

Comments
 (0)