debase-ruby_core_source 3.3.6 → 3.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.ruby-version +1 -0
- data/CHANGELOG.md +6 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/builtin.h +7 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/darray.h +1 -3
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/id.h +5 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/insns.inc +2 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/insns_info.inc +310 -175
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/basic_operators.h +1 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/bits.h +82 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/encoding.h +2 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/error.h +26 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/fixnum.h +1 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/gc.h +14 -6
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/imemo.h +6 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/io.h +1 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/parse.h +2 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/proc.h +1 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/ractor.h +4 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/sanitizers.h +31 -39
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/string.h +22 -10
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/thread.h +23 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/vm.h +1 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/method.h +1 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/optunifs.inc +1 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/parse.h +2 -2
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/ast.h +427 -3
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/defines.h +8 -7
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/diagnostic.h +1 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/extension.h +1 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/prism.h +47 -11
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/version.h +2 -2
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism_compile.h +5 -5
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/ractor_core.h +6 -6
- data/lib/debase/ruby_core_source/ruby-3.4.0/revision.h +5 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/rubyparser.h +3 -2
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/thread_pthread.h +0 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/version.h +1 -1
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/vm.inc +151 -88
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/vm_core.h +40 -12
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/vm_sync.h +3 -3
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/vmtc.inc +2 -0
- data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/yjit.h +1 -0
- data/lib/debase/ruby_core_source/version.rb +1 -1
- metadata +147 -293
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/darray.h +0 -191
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/debug_counter.h +0 -423
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/dln.h +0 -34
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/id.h +0 -343
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/insns.inc +0 -259
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/insns_info.inc +0 -9530
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/array.h +0 -151
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/basic_operators.h +0 -63
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/bits.h +0 -568
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/class.h +0 -283
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/error.h +0 -216
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/fixnum.h +0 -184
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/gc.h +0 -334
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/hash.h +0 -191
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/imemo.h +0 -260
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/io.h +0 -140
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/parse.h +0 -117
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/ractor.h +0 -6
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/sanitizers.h +0 -297
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/string.h +0 -182
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/thread.h +0 -79
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/internal/vm.h +0 -137
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/known_errors.inc +0 -1419
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/method.h +0 -255
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/optunifs.inc +0 -43
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/parse.h +0 -243
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/ast.h +0 -6245
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/defines.h +0 -206
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/diagnostic.h +0 -433
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/extension.h +0 -19
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/node.h +0 -150
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/options.h +0 -305
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/parser.h +0 -891
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/regexp.h +0 -33
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/static_literals.h +0 -120
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_char.h +0 -205
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_constant_pool.h +0 -226
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_integer.h +0 -119
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_newline_list.h +0 -102
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_string.h +0 -174
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/util/pm_string_list.h +0 -44
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism/version.h +0 -29
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/prism_compile.h +0 -88
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/ractor_core.h +0 -393
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/regint.h +0 -1010
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/revision.h +0 -5
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/rubyparser.h +0 -1430
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/shape.h +0 -233
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/symbol.h +0 -118
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/thread_pthread.h +0 -166
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/version.h +0 -69
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm.inc +0 -5643
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_callinfo.h +0 -605
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_core.h +0 -2236
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_insnhelper.h +0 -272
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vm_sync.h +0 -137
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview1/vmtc.inc +0 -253
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/addr2line.h +0 -22
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/builtin.h +0 -119
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/ccan/build_assert/build_assert.h +0 -40
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/ccan/check_type/check_type.h +0 -63
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/ccan/container_of/container_of.h +0 -142
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/ccan/list/list.h +0 -791
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/ccan/str/str.h +0 -17
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/constant.h +0 -53
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/encindex.h +0 -70
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/eval_intern.h +0 -324
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/hrtime.h +0 -237
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/id_table.h +0 -39
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/bignum.h +0 -244
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/cmdlineopt.h +0 -65
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/compar.h +0 -29
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/compile.h +0 -34
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/compilers.h +0 -107
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/complex.h +0 -29
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/cont.h +0 -35
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/dir.h +0 -16
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/enc.h +0 -19
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/encoding.h +0 -36
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/enum.h +0 -18
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/enumerator.h +0 -21
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/eval.h +0 -33
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/file.h +0 -38
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/inits.h +0 -47
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/load.h +0 -18
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/loadpath.h +0 -16
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/math.h +0 -23
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/missing.h +0 -19
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/numeric.h +0 -274
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/object.h +0 -63
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/proc.h +0 -30
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/process.h +0 -124
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/random.h +0 -17
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/range.h +0 -40
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/rational.h +0 -71
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/re.h +0 -28
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/ruby_parser.h +0 -102
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/serial.h +0 -23
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/signal.h +0 -24
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/st.h +0 -11
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/static_assert.h +0 -16
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/struct.h +0 -127
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/symbol.h +0 -45
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/time.h +0 -34
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/transcode.h +0 -23
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/util.h +0 -27
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/variable.h +0 -72
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal/warnings.h +0 -16
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/internal.h +0 -108
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/iseq.h +0 -340
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/node.h +0 -111
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/node_name.inc +0 -224
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/optinsn.inc +0 -128
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/parser_bits.h +0 -564
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/parser_node.h +0 -32
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/parser_st.h +0 -162
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/parser_value.h +0 -106
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/encoding.h +0 -283
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/pack.h +0 -163
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/prettyprint.h +0 -34
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/prism.h +0 -336
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/util/pm_buffer.h +0 -218
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/util/pm_list.h +0 -97
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/util/pm_memchr.h +0 -29
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/util/pm_strncasecmp.h +0 -32
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/prism/util/pm_strpbrk.h +0 -46
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/probes_helper.h +0 -42
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/regenc.h +0 -254
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/regparse.h +0 -371
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/revision.h +0 -5
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/rjit.h +0 -101
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/rjit_c.h +0 -165
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/ruby_assert.h +0 -14
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/ruby_atomic.h +0 -23
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/siphash.h +0 -48
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/thread_none.h +0 -21
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/thread_win32.h +0 -58
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/timev.h +0 -58
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/transcode_data.h +0 -138
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/variable.h +0 -39
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/vm_call_iseq_optimized.inc +0 -244
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/vm_debug.h +0 -124
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/vm_exec.h +0 -199
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/vm_opts.h +0 -67
- data/lib/debase/ruby_core_source/ruby-3.4.0-preview2/yjit.h +0 -79
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/addr2line.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/ccan/build_assert/build_assert.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/ccan/check_type/check_type.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/ccan/container_of/container_of.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/ccan/list/list.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/ccan/str/str.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/constant.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/debug_counter.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/dln.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/encindex.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/eval_intern.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/hrtime.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/id_table.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/array.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/bignum.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/class.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/cmdlineopt.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/compar.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/compile.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/compilers.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/complex.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/cont.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/dir.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/enc.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/enum.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/enumerator.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/eval.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/file.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/internal/hash.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/inits.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/load.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/loadpath.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/math.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/missing.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/numeric.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/object.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/process.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/random.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/range.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/rational.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/re.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/ruby_parser.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/serial.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/signal.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/st.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/static_assert.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/struct.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/symbol.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/time.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/transcode.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/util.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/variable.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal/warnings.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/internal.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/iseq.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/known_errors.inc +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/node.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/node_name.inc +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/optinsn.inc +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/parser_bits.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/parser_node.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/parser_st.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/parser_value.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/encoding.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/node.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/options.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/pack.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/parser.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/prettyprint.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/regexp.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/static_literals.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/util/pm_buffer.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/util/pm_char.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/util/pm_constant_pool.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/util/pm_integer.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/util/pm_list.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/util/pm_memchr.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/util/pm_newline_list.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/prism/util/pm_string.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/util/pm_strncasecmp.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/prism/util/pm_strpbrk.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/probes_helper.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/regenc.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/regint.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/regparse.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/rjit.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/rjit_c.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/ruby_assert.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/ruby_atomic.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/shape.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/siphash.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/symbol.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/thread_none.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/thread_win32.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/timev.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/transcode_data.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/variable.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/vm_call_iseq_optimized.inc +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/vm_callinfo.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/vm_debug.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/vm_exec.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview2 → ruby-3.4.0}/vm_insnhelper.h +0 -0
- /data/lib/debase/ruby_core_source/{ruby-3.4.0-preview1 → ruby-3.4.0}/vm_opts.h +0 -0
@@ -1,233 +0,0 @@
|
|
1
|
-
#ifndef RUBY_SHAPE_H
|
2
|
-
#define RUBY_SHAPE_H
|
3
|
-
|
4
|
-
#include "internal/gc.h"
|
5
|
-
|
6
|
-
#if (SIZEOF_UINT64_T <= SIZEOF_VALUE)
|
7
|
-
|
8
|
-
#define SIZEOF_SHAPE_T 4
|
9
|
-
#define SHAPE_IN_BASIC_FLAGS 1
|
10
|
-
typedef uint32_t attr_index_t;
|
11
|
-
typedef uint32_t shape_id_t;
|
12
|
-
# define SHAPE_ID_NUM_BITS 32
|
13
|
-
|
14
|
-
#else
|
15
|
-
|
16
|
-
#define SIZEOF_SHAPE_T 2
|
17
|
-
#define SHAPE_IN_BASIC_FLAGS 0
|
18
|
-
typedef uint16_t attr_index_t;
|
19
|
-
typedef uint16_t shape_id_t;
|
20
|
-
# define SHAPE_ID_NUM_BITS 16
|
21
|
-
|
22
|
-
#endif
|
23
|
-
|
24
|
-
typedef uint32_t redblack_id_t;
|
25
|
-
|
26
|
-
#define MAX_IVARS (attr_index_t)(-1)
|
27
|
-
|
28
|
-
# define SHAPE_MASK (((uintptr_t)1 << SHAPE_ID_NUM_BITS) - 1)
|
29
|
-
# define SHAPE_FLAG_MASK (((VALUE)-1) >> SHAPE_ID_NUM_BITS)
|
30
|
-
|
31
|
-
# define SHAPE_FLAG_SHIFT ((SIZEOF_VALUE * 8) - SHAPE_ID_NUM_BITS)
|
32
|
-
|
33
|
-
# define SHAPE_MAX_VARIATIONS 8
|
34
|
-
|
35
|
-
# define INVALID_SHAPE_ID SHAPE_MASK
|
36
|
-
# define ROOT_SHAPE_ID 0x0
|
37
|
-
|
38
|
-
# define SPECIAL_CONST_SHAPE_ID (ROOT_SHAPE_ID + 1)
|
39
|
-
# define OBJ_TOO_COMPLEX_SHAPE_ID (SPECIAL_CONST_SHAPE_ID + 1)
|
40
|
-
# define FIRST_T_OBJECT_SHAPE_ID (OBJ_TOO_COMPLEX_SHAPE_ID + 1)
|
41
|
-
|
42
|
-
typedef struct redblack_node redblack_node_t;
|
43
|
-
|
44
|
-
struct rb_shape {
|
45
|
-
struct rb_id_table * edges; // id_table from ID (ivar) to next shape
|
46
|
-
ID edge_name; // ID (ivar) for transition from parent to rb_shape
|
47
|
-
attr_index_t next_iv_index;
|
48
|
-
uint32_t capacity; // Total capacity of the object with this shape
|
49
|
-
uint8_t type;
|
50
|
-
uint8_t size_pool_index;
|
51
|
-
shape_id_t parent_id;
|
52
|
-
redblack_node_t * ancestor_index;
|
53
|
-
};
|
54
|
-
|
55
|
-
typedef struct rb_shape rb_shape_t;
|
56
|
-
|
57
|
-
struct redblack_node {
|
58
|
-
ID key;
|
59
|
-
rb_shape_t * value;
|
60
|
-
redblack_id_t l;
|
61
|
-
redblack_id_t r;
|
62
|
-
};
|
63
|
-
|
64
|
-
enum shape_type {
|
65
|
-
SHAPE_ROOT,
|
66
|
-
SHAPE_IVAR,
|
67
|
-
SHAPE_FROZEN,
|
68
|
-
SHAPE_T_OBJECT,
|
69
|
-
SHAPE_OBJ_TOO_COMPLEX,
|
70
|
-
};
|
71
|
-
|
72
|
-
typedef struct {
|
73
|
-
/* object shapes */
|
74
|
-
rb_shape_t *shape_list;
|
75
|
-
rb_shape_t *root_shape;
|
76
|
-
shape_id_t next_shape_id;
|
77
|
-
|
78
|
-
redblack_node_t *shape_cache;
|
79
|
-
unsigned int cache_size;
|
80
|
-
} rb_shape_tree_t;
|
81
|
-
RUBY_EXTERN rb_shape_tree_t *rb_shape_tree_ptr;
|
82
|
-
|
83
|
-
static inline rb_shape_tree_t *
|
84
|
-
rb_current_shape_tree(void)
|
85
|
-
{
|
86
|
-
return rb_shape_tree_ptr;
|
87
|
-
}
|
88
|
-
#define GET_SHAPE_TREE() rb_current_shape_tree()
|
89
|
-
|
90
|
-
static inline shape_id_t
|
91
|
-
get_shape_id_from_flags(VALUE obj)
|
92
|
-
{
|
93
|
-
RUBY_ASSERT(!RB_SPECIAL_CONST_P(obj));
|
94
|
-
return (shape_id_t)(SHAPE_MASK & ((RBASIC(obj)->flags) >> SHAPE_FLAG_SHIFT));
|
95
|
-
}
|
96
|
-
|
97
|
-
static inline void
|
98
|
-
set_shape_id_in_flags(VALUE obj, shape_id_t shape_id)
|
99
|
-
{
|
100
|
-
// Ractors are occupying the upper 32 bits of flags, but only in debug mode
|
101
|
-
// Object shapes are occupying top bits
|
102
|
-
RBASIC(obj)->flags &= SHAPE_FLAG_MASK;
|
103
|
-
RBASIC(obj)->flags |= ((VALUE)(shape_id) << SHAPE_FLAG_SHIFT);
|
104
|
-
}
|
105
|
-
|
106
|
-
|
107
|
-
#if SHAPE_IN_BASIC_FLAGS
|
108
|
-
static inline shape_id_t
|
109
|
-
RBASIC_SHAPE_ID(VALUE obj)
|
110
|
-
{
|
111
|
-
return get_shape_id_from_flags(obj);
|
112
|
-
}
|
113
|
-
|
114
|
-
static inline void
|
115
|
-
RBASIC_SET_SHAPE_ID(VALUE obj, shape_id_t shape_id)
|
116
|
-
{
|
117
|
-
set_shape_id_in_flags(obj, shape_id);
|
118
|
-
}
|
119
|
-
#endif
|
120
|
-
|
121
|
-
static inline shape_id_t
|
122
|
-
ROBJECT_SHAPE_ID(VALUE obj)
|
123
|
-
{
|
124
|
-
RBIMPL_ASSERT_TYPE(obj, RUBY_T_OBJECT);
|
125
|
-
return get_shape_id_from_flags(obj);
|
126
|
-
}
|
127
|
-
|
128
|
-
static inline void
|
129
|
-
ROBJECT_SET_SHAPE_ID(VALUE obj, shape_id_t shape_id)
|
130
|
-
{
|
131
|
-
RBIMPL_ASSERT_TYPE(obj, RUBY_T_OBJECT);
|
132
|
-
set_shape_id_in_flags(obj, shape_id);
|
133
|
-
}
|
134
|
-
|
135
|
-
static inline shape_id_t
|
136
|
-
RCLASS_SHAPE_ID(VALUE obj)
|
137
|
-
{
|
138
|
-
RUBY_ASSERT(RB_TYPE_P(obj, T_CLASS) || RB_TYPE_P(obj, T_MODULE));
|
139
|
-
return get_shape_id_from_flags(obj);
|
140
|
-
}
|
141
|
-
|
142
|
-
static inline void
|
143
|
-
RCLASS_SET_SHAPE_ID(VALUE obj, shape_id_t shape_id)
|
144
|
-
{
|
145
|
-
RUBY_ASSERT(RB_TYPE_P(obj, T_CLASS) || RB_TYPE_P(obj, T_MODULE));
|
146
|
-
set_shape_id_in_flags(obj, shape_id);
|
147
|
-
}
|
148
|
-
|
149
|
-
rb_shape_t * rb_shape_get_root_shape(void);
|
150
|
-
int32_t rb_shape_id_offset(void);
|
151
|
-
|
152
|
-
rb_shape_t * rb_shape_get_parent(rb_shape_t * shape);
|
153
|
-
|
154
|
-
RUBY_FUNC_EXPORTED rb_shape_t *rb_shape_get_shape_by_id(shape_id_t shape_id);
|
155
|
-
RUBY_FUNC_EXPORTED shape_id_t rb_shape_get_shape_id(VALUE obj);
|
156
|
-
rb_shape_t * rb_shape_get_next_iv_shape(rb_shape_t * shape, ID id);
|
157
|
-
bool rb_shape_get_iv_index(rb_shape_t * shape, ID id, attr_index_t * value);
|
158
|
-
bool rb_shape_get_iv_index_with_hint(shape_id_t shape_id, ID id, attr_index_t * value, shape_id_t *shape_id_hint);
|
159
|
-
RUBY_FUNC_EXPORTED bool rb_shape_obj_too_complex(VALUE obj);
|
160
|
-
|
161
|
-
void rb_shape_set_shape(VALUE obj, rb_shape_t* shape);
|
162
|
-
rb_shape_t* rb_shape_get_shape(VALUE obj);
|
163
|
-
int rb_shape_frozen_shape_p(rb_shape_t* shape);
|
164
|
-
rb_shape_t* rb_shape_transition_shape_frozen(VALUE obj);
|
165
|
-
bool rb_shape_transition_shape_remove_ivar(VALUE obj, ID id, rb_shape_t *shape, VALUE * removed);
|
166
|
-
rb_shape_t* rb_shape_get_next(rb_shape_t* shape, VALUE obj, ID id);
|
167
|
-
|
168
|
-
rb_shape_t * rb_shape_rebuild_shape(rb_shape_t * initial_shape, rb_shape_t * dest_shape);
|
169
|
-
|
170
|
-
static inline uint32_t
|
171
|
-
ROBJECT_IV_CAPACITY(VALUE obj)
|
172
|
-
{
|
173
|
-
RBIMPL_ASSERT_TYPE(obj, RUBY_T_OBJECT);
|
174
|
-
// Asking for capacity doesn't make sense when the object is using
|
175
|
-
// a hash table for storing instance variables
|
176
|
-
RUBY_ASSERT(!rb_shape_obj_too_complex(obj));
|
177
|
-
return rb_shape_get_shape_by_id(ROBJECT_SHAPE_ID(obj))->capacity;
|
178
|
-
}
|
179
|
-
|
180
|
-
static inline st_table *
|
181
|
-
ROBJECT_IV_HASH(VALUE obj)
|
182
|
-
{
|
183
|
-
RBIMPL_ASSERT_TYPE(obj, RUBY_T_OBJECT);
|
184
|
-
RUBY_ASSERT(rb_shape_obj_too_complex(obj));
|
185
|
-
return (st_table *)ROBJECT(obj)->as.heap.ivptr;
|
186
|
-
}
|
187
|
-
|
188
|
-
static inline void
|
189
|
-
ROBJECT_SET_IV_HASH(VALUE obj, const st_table *tbl)
|
190
|
-
{
|
191
|
-
RBIMPL_ASSERT_TYPE(obj, RUBY_T_OBJECT);
|
192
|
-
RUBY_ASSERT(rb_shape_obj_too_complex(obj));
|
193
|
-
ROBJECT(obj)->as.heap.ivptr = (VALUE *)tbl;
|
194
|
-
}
|
195
|
-
|
196
|
-
size_t rb_id_table_size(const struct rb_id_table *tbl);
|
197
|
-
|
198
|
-
static inline uint32_t
|
199
|
-
ROBJECT_IV_COUNT(VALUE obj)
|
200
|
-
{
|
201
|
-
if (rb_shape_obj_too_complex(obj)) {
|
202
|
-
return (uint32_t)rb_st_table_size(ROBJECT_IV_HASH(obj));
|
203
|
-
}
|
204
|
-
else {
|
205
|
-
RBIMPL_ASSERT_TYPE(obj, RUBY_T_OBJECT);
|
206
|
-
RUBY_ASSERT(!rb_shape_obj_too_complex(obj));
|
207
|
-
return rb_shape_get_shape_by_id(ROBJECT_SHAPE_ID(obj))->next_iv_index;
|
208
|
-
}
|
209
|
-
}
|
210
|
-
|
211
|
-
static inline uint32_t
|
212
|
-
RBASIC_IV_COUNT(VALUE obj)
|
213
|
-
{
|
214
|
-
return rb_shape_get_shape_by_id(rb_shape_get_shape_id(obj))->next_iv_index;
|
215
|
-
}
|
216
|
-
|
217
|
-
rb_shape_t *rb_shape_traverse_from_new_root(rb_shape_t *initial_shape, rb_shape_t *orig_shape);
|
218
|
-
|
219
|
-
bool rb_shape_set_shape_id(VALUE obj, shape_id_t shape_id);
|
220
|
-
|
221
|
-
VALUE rb_obj_debug_shape(VALUE self, VALUE obj);
|
222
|
-
|
223
|
-
// For ext/objspace
|
224
|
-
RUBY_SYMBOL_EXPORT_BEGIN
|
225
|
-
typedef void each_shape_callback(rb_shape_t * shape, void *data);
|
226
|
-
void rb_shape_each_shape(each_shape_callback callback, void *data);
|
227
|
-
size_t rb_shape_memsize(rb_shape_t *shape);
|
228
|
-
size_t rb_shape_edges_count(rb_shape_t *shape);
|
229
|
-
size_t rb_shape_depth(rb_shape_t *shape);
|
230
|
-
shape_id_t rb_shape_id(rb_shape_t * shape);
|
231
|
-
RUBY_SYMBOL_EXPORT_END
|
232
|
-
|
233
|
-
#endif
|
@@ -1,118 +0,0 @@
|
|
1
|
-
#ifndef RUBY_SYMBOL_H
|
2
|
-
#define RUBY_SYMBOL_H 1
|
3
|
-
/**********************************************************************
|
4
|
-
|
5
|
-
symbol.h -
|
6
|
-
|
7
|
-
$Author$
|
8
|
-
created at: Tue Jul 8 15:49:54 JST 2014
|
9
|
-
|
10
|
-
Copyright (C) 2014 Yukihiro Matsumoto
|
11
|
-
|
12
|
-
**********************************************************************/
|
13
|
-
|
14
|
-
#include "id.h"
|
15
|
-
#include "ruby/encoding.h"
|
16
|
-
|
17
|
-
#define DYNAMIC_ID_P(id) (!(id&ID_STATIC_SYM)&&id>tLAST_OP_ID)
|
18
|
-
#define STATIC_ID2SYM(id) (((VALUE)(id)<<RUBY_SPECIAL_SHIFT)|SYMBOL_FLAG)
|
19
|
-
|
20
|
-
#ifdef HAVE_BUILTIN___BUILTIN_CONSTANT_P
|
21
|
-
#define rb_id2sym(id) \
|
22
|
-
RB_GNUC_EXTENSION_BLOCK(__builtin_constant_p(id) && !DYNAMIC_ID_P(id) ? \
|
23
|
-
STATIC_ID2SYM(id) : rb_id2sym(id))
|
24
|
-
#endif
|
25
|
-
|
26
|
-
struct RSymbol {
|
27
|
-
struct RBasic basic;
|
28
|
-
st_index_t hashval;
|
29
|
-
VALUE fstr;
|
30
|
-
ID id;
|
31
|
-
};
|
32
|
-
|
33
|
-
#define RSYMBOL(obj) ((struct RSymbol *)(obj))
|
34
|
-
|
35
|
-
#define is_notop_id(id) ((id)>tLAST_OP_ID)
|
36
|
-
#define is_local_id(id) (id_type(id)==ID_LOCAL)
|
37
|
-
#define is_global_id(id) (id_type(id)==ID_GLOBAL)
|
38
|
-
#define is_instance_id(id) (id_type(id)==ID_INSTANCE)
|
39
|
-
#define is_attrset_id(id) ((id)==idASET||id_type(id)==ID_ATTRSET)
|
40
|
-
#define is_const_id(id) (id_type(id)==ID_CONST)
|
41
|
-
#define is_class_id(id) (id_type(id)==ID_CLASS)
|
42
|
-
#define is_junk_id(id) (id_type(id)==ID_JUNK)
|
43
|
-
|
44
|
-
static inline int
|
45
|
-
id_type(ID id)
|
46
|
-
{
|
47
|
-
if (is_notop_id(id)) {
|
48
|
-
return (int)(id&ID_SCOPE_MASK);
|
49
|
-
}
|
50
|
-
else {
|
51
|
-
return -1;
|
52
|
-
}
|
53
|
-
}
|
54
|
-
|
55
|
-
typedef uint32_t rb_id_serial_t;
|
56
|
-
static const uint32_t RB_ID_SERIAL_MAX = /* 256M on LP32 */
|
57
|
-
UINT32_MAX >>
|
58
|
-
((sizeof(ID)-sizeof(rb_id_serial_t))*CHAR_BIT < RUBY_ID_SCOPE_SHIFT ?
|
59
|
-
RUBY_ID_SCOPE_SHIFT : 0);
|
60
|
-
|
61
|
-
typedef struct {
|
62
|
-
rb_id_serial_t last_id;
|
63
|
-
st_table *str_sym;
|
64
|
-
VALUE ids;
|
65
|
-
VALUE dsymbol_fstr_hash;
|
66
|
-
} rb_symbols_t;
|
67
|
-
|
68
|
-
static inline rb_id_serial_t
|
69
|
-
rb_id_to_serial(ID id)
|
70
|
-
{
|
71
|
-
if (is_notop_id(id)) {
|
72
|
-
return (rb_id_serial_t)(id >> ID_SCOPE_SHIFT);
|
73
|
-
}
|
74
|
-
else {
|
75
|
-
return (rb_id_serial_t)id;
|
76
|
-
}
|
77
|
-
}
|
78
|
-
|
79
|
-
static inline int
|
80
|
-
sym_type(VALUE sym)
|
81
|
-
{
|
82
|
-
ID id;
|
83
|
-
if (STATIC_SYM_P(sym)) {
|
84
|
-
id = RSHIFT(sym, RUBY_SPECIAL_SHIFT);
|
85
|
-
if (id<=tLAST_OP_ID) {
|
86
|
-
return -1;
|
87
|
-
}
|
88
|
-
}
|
89
|
-
else {
|
90
|
-
id = RSYMBOL(sym)->id;
|
91
|
-
}
|
92
|
-
return (int)(id&ID_SCOPE_MASK);
|
93
|
-
}
|
94
|
-
|
95
|
-
#define is_local_sym(sym) (sym_type(sym)==ID_LOCAL)
|
96
|
-
#define is_global_sym(sym) (sym_type(sym)==ID_GLOBAL)
|
97
|
-
#define is_instance_sym(sym) (sym_type(sym)==ID_INSTANCE)
|
98
|
-
#define is_attrset_sym(sym) (sym_type(sym)==ID_ATTRSET)
|
99
|
-
#define is_const_sym(sym) (sym_type(sym)==ID_CONST)
|
100
|
-
#define is_class_sym(sym) (sym_type(sym)==ID_CLASS)
|
101
|
-
#define is_junk_sym(sym) (sym_type(sym)==ID_JUNK)
|
102
|
-
|
103
|
-
RUBY_FUNC_EXPORTED const uint_least32_t ruby_global_name_punct_bits[(0x7e - 0x20 + 31) / 32];
|
104
|
-
|
105
|
-
static inline int
|
106
|
-
is_global_name_punct(const int c)
|
107
|
-
{
|
108
|
-
if (c <= 0x20 || 0x7e < c) return 0;
|
109
|
-
return (ruby_global_name_punct_bits[(c - 0x20) / 32] >> (c % 32)) & 1;
|
110
|
-
}
|
111
|
-
|
112
|
-
RUBY_SYMBOL_EXPORT_BEGIN
|
113
|
-
|
114
|
-
int rb_enc_symname_type(const char *name, long len, rb_encoding *enc, unsigned int allowed_attrset);
|
115
|
-
size_t rb_sym_immortal_count(void);
|
116
|
-
|
117
|
-
RUBY_SYMBOL_EXPORT_END
|
118
|
-
#endif
|
@@ -1,166 +0,0 @@
|
|
1
|
-
#ifndef RUBY_THREAD_PTHREAD_H
|
2
|
-
#define RUBY_THREAD_PTHREAD_H
|
3
|
-
/**********************************************************************
|
4
|
-
|
5
|
-
thread_pthread.h -
|
6
|
-
|
7
|
-
$Author$
|
8
|
-
|
9
|
-
Copyright (C) 2004-2007 Koichi Sasada
|
10
|
-
|
11
|
-
**********************************************************************/
|
12
|
-
|
13
|
-
#ifdef HAVE_PTHREAD_NP_H
|
14
|
-
#include <pthread_np.h>
|
15
|
-
#endif
|
16
|
-
|
17
|
-
#define RB_NATIVETHREAD_LOCK_INIT PTHREAD_MUTEX_INITIALIZER
|
18
|
-
#define RB_NATIVETHREAD_COND_INIT PTHREAD_COND_INITIALIZER
|
19
|
-
|
20
|
-
// per-Thead scheduler helper data
|
21
|
-
struct rb_thread_sched_item {
|
22
|
-
struct {
|
23
|
-
struct ccan_list_node ubf;
|
24
|
-
|
25
|
-
// connected to ractor->threads.sched.reqdyq
|
26
|
-
// locked by ractor->threads.sched.lock
|
27
|
-
struct ccan_list_node readyq;
|
28
|
-
|
29
|
-
// connected to vm->ractor.sched.timeslice_threads
|
30
|
-
// locked by vm->ractor.sched.lock
|
31
|
-
struct ccan_list_node timeslice_threads;
|
32
|
-
|
33
|
-
// connected to vm->ractor.sched.running_threads
|
34
|
-
// locked by vm->ractor.sched.lock
|
35
|
-
struct ccan_list_node running_threads;
|
36
|
-
|
37
|
-
// connected to vm->ractor.sched.zombie_threads
|
38
|
-
struct ccan_list_node zombie_threads;
|
39
|
-
} node;
|
40
|
-
|
41
|
-
// this data should be protected by timer_th.waiting_lock
|
42
|
-
struct {
|
43
|
-
enum thread_sched_waiting_flag {
|
44
|
-
thread_sched_waiting_none = 0x00,
|
45
|
-
thread_sched_waiting_timeout = 0x01,
|
46
|
-
thread_sched_waiting_io_read = 0x02,
|
47
|
-
thread_sched_waiting_io_write = 0x08,
|
48
|
-
thread_sched_waiting_io_force = 0x40, // ignore readable
|
49
|
-
} flags;
|
50
|
-
|
51
|
-
struct {
|
52
|
-
// should be compat with hrtime.h
|
53
|
-
#ifdef MY_RUBY_BUILD_MAY_TIME_TRAVEL
|
54
|
-
int128_t timeout;
|
55
|
-
#else
|
56
|
-
uint64_t timeout;
|
57
|
-
#endif
|
58
|
-
int fd; // -1 for timeout only
|
59
|
-
int result;
|
60
|
-
} data;
|
61
|
-
|
62
|
-
// connected to timer_th.waiting
|
63
|
-
struct ccan_list_node node;
|
64
|
-
} waiting_reason;
|
65
|
-
|
66
|
-
bool finished;
|
67
|
-
bool malloc_stack;
|
68
|
-
void *context_stack;
|
69
|
-
struct coroutine_context *context;
|
70
|
-
};
|
71
|
-
|
72
|
-
struct rb_native_thread {
|
73
|
-
rb_atomic_t serial;
|
74
|
-
struct rb_vm_struct *vm;
|
75
|
-
|
76
|
-
rb_nativethread_id_t thread_id;
|
77
|
-
|
78
|
-
#ifdef RB_THREAD_T_HAS_NATIVE_ID
|
79
|
-
int tid;
|
80
|
-
#endif
|
81
|
-
|
82
|
-
struct rb_thread_struct *running_thread;
|
83
|
-
|
84
|
-
// to control native thread
|
85
|
-
#if defined(__GLIBC__) || defined(__FreeBSD__)
|
86
|
-
union
|
87
|
-
#else
|
88
|
-
/*
|
89
|
-
* assume the platform condvars are badly implemented and have a
|
90
|
-
* "memory" of which mutex they're associated with
|
91
|
-
*/
|
92
|
-
struct
|
93
|
-
#endif
|
94
|
-
{
|
95
|
-
rb_nativethread_cond_t intr; /* th->interrupt_lock */
|
96
|
-
rb_nativethread_cond_t readyq; /* use sched->lock */
|
97
|
-
} cond;
|
98
|
-
|
99
|
-
#ifdef USE_SIGALTSTACK
|
100
|
-
void *altstack;
|
101
|
-
#endif
|
102
|
-
|
103
|
-
struct coroutine_context *nt_context;
|
104
|
-
int dedicated;
|
105
|
-
|
106
|
-
size_t machine_stack_maxsize;
|
107
|
-
};
|
108
|
-
|
109
|
-
#undef except
|
110
|
-
#undef try
|
111
|
-
#undef leave
|
112
|
-
#undef finally
|
113
|
-
|
114
|
-
// per-Ractor
|
115
|
-
struct rb_thread_sched {
|
116
|
-
rb_nativethread_lock_t lock_;
|
117
|
-
#if VM_CHECK_MODE
|
118
|
-
struct rb_thread_struct *lock_owner;
|
119
|
-
#endif
|
120
|
-
struct rb_thread_struct *running; // running thread or NULL
|
121
|
-
bool is_running;
|
122
|
-
bool is_running_timeslice;
|
123
|
-
bool enable_mn_threads;
|
124
|
-
|
125
|
-
struct ccan_list_head readyq;
|
126
|
-
int readyq_cnt;
|
127
|
-
// ractor scheduling
|
128
|
-
struct ccan_list_node grq_node;
|
129
|
-
};
|
130
|
-
|
131
|
-
#ifdef RB_THREAD_LOCAL_SPECIFIER
|
132
|
-
NOINLINE(void rb_current_ec_set(struct rb_execution_context_struct *));
|
133
|
-
NOINLINE(struct rb_execution_context_struct *rb_current_ec_noinline(void));
|
134
|
-
|
135
|
-
# ifdef __APPLE__
|
136
|
-
// on Darwin, TLS can not be accessed across .so
|
137
|
-
NOINLINE(struct rb_execution_context_struct *rb_current_ec(void));
|
138
|
-
# else
|
139
|
-
RUBY_EXTERN RB_THREAD_LOCAL_SPECIFIER struct rb_execution_context_struct *ruby_current_ec;
|
140
|
-
|
141
|
-
// for RUBY_DEBUG_LOG()
|
142
|
-
RUBY_EXTERN RB_THREAD_LOCAL_SPECIFIER rb_atomic_t ruby_nt_serial;
|
143
|
-
#define RUBY_NT_SERIAL 1
|
144
|
-
# endif
|
145
|
-
#else
|
146
|
-
typedef pthread_key_t native_tls_key_t;
|
147
|
-
|
148
|
-
static inline void *
|
149
|
-
native_tls_get(native_tls_key_t key)
|
150
|
-
{
|
151
|
-
// return value should be checked by caller
|
152
|
-
return pthread_getspecific(key);
|
153
|
-
}
|
154
|
-
|
155
|
-
static inline void
|
156
|
-
native_tls_set(native_tls_key_t key, void *ptr)
|
157
|
-
{
|
158
|
-
if (UNLIKELY(pthread_setspecific(key, ptr) != 0)) {
|
159
|
-
rb_bug("pthread_setspecific error");
|
160
|
-
}
|
161
|
-
}
|
162
|
-
|
163
|
-
RUBY_EXTERN native_tls_key_t ruby_current_ec_key;
|
164
|
-
#endif
|
165
|
-
|
166
|
-
#endif /* RUBY_THREAD_PTHREAD_H */
|
@@ -1,69 +0,0 @@
|
|
1
|
-
#ifndef RUBY_TOPLEVEL_VERSION_H /*-*-C-*-vi:se ft=c:*/
|
2
|
-
#define RUBY_TOPLEVEL_VERSION_H
|
3
|
-
/**
|
4
|
-
* @author Ruby developers <ruby-core@ruby-lang.org>
|
5
|
-
* @copyright This file is a part of the programming language Ruby.
|
6
|
-
* Permission is hereby granted, to either redistribute and/or
|
7
|
-
* modify this file, provided that the conditions mentioned in the
|
8
|
-
* file COPYING are met. Consult the file for details.
|
9
|
-
*/
|
10
|
-
# define RUBY_VERSION_MAJOR RUBY_API_VERSION_MAJOR
|
11
|
-
# define RUBY_VERSION_MINOR RUBY_API_VERSION_MINOR
|
12
|
-
#define RUBY_VERSION_TEENY 0
|
13
|
-
#define RUBY_RELEASE_DATE RUBY_RELEASE_YEAR_STR"-"RUBY_RELEASE_MONTH_STR"-"RUBY_RELEASE_DAY_STR
|
14
|
-
#define RUBY_PATCHLEVEL -1
|
15
|
-
|
16
|
-
#include "ruby/version.h"
|
17
|
-
#include "ruby/internal/abi.h"
|
18
|
-
|
19
|
-
#ifndef RUBY_REVISION
|
20
|
-
#include "revision.h"
|
21
|
-
|
22
|
-
#ifndef TOKEN_PASTE
|
23
|
-
#define TOKEN_PASTE(x,y) x##y
|
24
|
-
#endif
|
25
|
-
#define ONLY_ONE_DIGIT(x) TOKEN_PASTE(10,x) < 1000
|
26
|
-
#define WITH_ZERO_PADDING(x) TOKEN_PASTE(0,x)
|
27
|
-
#define RUBY_BIRTH_YEAR_STR STRINGIZE(RUBY_BIRTH_YEAR)
|
28
|
-
#define RUBY_RELEASE_YEAR_STR STRINGIZE(RUBY_RELEASE_YEAR)
|
29
|
-
#if ONLY_ONE_DIGIT(RUBY_RELEASE_MONTH)
|
30
|
-
#define RUBY_RELEASE_MONTH_STR STRINGIZE(WITH_ZERO_PADDING(RUBY_RELEASE_MONTH))
|
31
|
-
#else
|
32
|
-
#define RUBY_RELEASE_MONTH_STR STRINGIZE(RUBY_RELEASE_MONTH)
|
33
|
-
#endif
|
34
|
-
#if ONLY_ONE_DIGIT(RUBY_RELEASE_DAY)
|
35
|
-
#define RUBY_RELEASE_DAY_STR STRINGIZE(WITH_ZERO_PADDING(RUBY_RELEASE_DAY))
|
36
|
-
#else
|
37
|
-
#define RUBY_RELEASE_DAY_STR STRINGIZE(RUBY_RELEASE_DAY)
|
38
|
-
#endif
|
39
|
-
|
40
|
-
#endif
|
41
|
-
|
42
|
-
#ifdef RUBY_ABI_VERSION
|
43
|
-
# define RUBY_ABI_VERSION_SUFFIX "+"STRINGIZE(RUBY_ABI_VERSION)
|
44
|
-
#else
|
45
|
-
# define RUBY_ABI_VERSION_SUFFIX ""
|
46
|
-
#endif
|
47
|
-
#if !defined RUBY_LIB_VERSION && defined RUBY_LIB_VERSION_STYLE
|
48
|
-
# if RUBY_LIB_VERSION_STYLE == 3
|
49
|
-
# define RUBY_LIB_VERSION STRINGIZE(RUBY_API_VERSION_MAJOR)"."STRINGIZE(RUBY_API_VERSION_MINOR) \
|
50
|
-
"."STRINGIZE(RUBY_API_VERSION_TEENY) RUBY_ABI_VERSION_SUFFIX
|
51
|
-
# elif RUBY_LIB_VERSION_STYLE == 2
|
52
|
-
# define RUBY_LIB_VERSION STRINGIZE(RUBY_API_VERSION_MAJOR)"."STRINGIZE(RUBY_API_VERSION_MINOR) \
|
53
|
-
RUBY_ABI_VERSION_SUFFIX
|
54
|
-
# endif
|
55
|
-
#endif
|
56
|
-
|
57
|
-
#if RUBY_PATCHLEVEL == -1
|
58
|
-
# ifdef RUBY_PATCHLEVEL_NAME
|
59
|
-
# define RUBY_PATCHLEVEL_STR STRINGIZE(RUBY_PATCHLEVEL_NAME)
|
60
|
-
# else
|
61
|
-
# define RUBY_PATCHLEVEL_STR "preview1"
|
62
|
-
# endif
|
63
|
-
#elif defined RUBY_ABI_VERSION
|
64
|
-
# error RUBY_ABI_VERSION is defined in non-development branch
|
65
|
-
#else
|
66
|
-
# define RUBY_PATCHLEVEL_STR ""
|
67
|
-
#endif
|
68
|
-
|
69
|
-
#endif /* RUBY_TOPLEVEL_VERSION_H */
|