This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-: 0:Source:insns.def | |
-: 0:Graph:vm.gcno | |
-: 0:Data:vm.gcda | |
-: 0:Runs:387 | |
-: 0:Programs:1 | |
-: 1:/** ##skip -*- mode:c; style:ruby; coding: utf-8 -*- | |
-: 2: insns.def - YARV instruction definitions | |
-: 3: | |
-: 4: $Author: $ | |
-: 5: created at: 04/01/01 01:17:55 JST |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
zsh % ./miniruby --dump=insns -ve '$_' | |
ruby 2.5.0dev (2017-01-17) [x86_64-darwin15] | |
-e:1: warning: possibly useless use of a variable in void context | |
== disasm: #<ISeq:<main>@-e>============================================ | |
0000 trace 1 ( 1) | |
0002 getglobal $_ | |
0004 leave |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
zsh % ./miniruby --dump=insns -ve '$~ = 1234' | |
ruby 2.5.0dev (2017-01-17) [x86_64-darwin15] | |
== disasm: #<ISeq:<main>@-e>============================================ | |
0000 trace 1 ( 1) | |
0002 putobject 1234 | |
0004 dup | |
0005 setglobal $~ | |
0007 leave |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
zsh % ./miniruby --dump=insns -ve '[*ary1, *ary2]' | |
ruby 2.5.0dev (2017-01-17) [x86_64-darwin15] | |
== disasm: #<ISeq:<main>@-e>============================================ | |
0000 trace 1 ( 1) | |
0002 putself | |
0003 opt_send_without_block <callinfo!mid:ary1, argc:0, FCALL|VCALL|ARGS_SIMPLE>, <callcache> | |
0006 splatarray true | |
0008 putself | |
0009 opt_send_without_block <callinfo!mid:ary2, argc:0, FCALL|VCALL|ARGS_SIMPLE>, <callcache> | |
0012 concatarray |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /your/favourite/path/to/bundler | |
# -*- coding: utf-8 -*- | |
# -*- frozen_string_literal: true -*- | |
# -*- warn_indent: true -*- | |
source 'https://rubygems.org' | |
gem 'test-unit-full' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /your/favourite/path/to/ruby | |
# -*- coding: utf-8 -*- | |
# -*- frozen_string_literal: true -*- | |
# -*- warn_indent: true -*- | |
require 'redcarpet' | |
class MD2DOM < Redcarpet::Render::Base | |
def preprocess str | |
@sexp = [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 8ecef9e3ed8003a1cb6c1601cfa56d82f70e9900 Mon Sep 17 00:00:00 2001 | |
From: "Urabe, Shyouhei" <[email protected]> | |
Date: Wed, 8 Mar 2017 13:14:04 +0900 | |
Subject: [PATCH] re-introduce __builtin_add_overflow | |
r57789 (74cdd89) was gradually "improve"d by naruse through r57793 to | |
r57806, resulted in reverting the efect of r57789 while retaining its | |
complexity. I think the current situation is slightly worse than | |
before (same output complicated source code). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Index: include/ruby/ruby.h | |
=================================================================== | |
--- include/ruby/ruby.h (revision 57788) | |
+++ include/ruby/ruby.h (revision 57807) | |
@@ -1504,6 +1504,17 @@ | |
} | |
#endif | |
+static inline int | |
+rb_long_is_fixable_p(long v) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC = gcc-4 | |
LD = ld | |
LDSHARED = gcc-4 -dynamic -bundle | |
CFLAGS = -O3 -fno-fast-math -ggdb3 -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wno-tautological-compare -Wno-parentheses-equality -Wno-constant-logical-operand -Wno-self-assign -Wunused-variable -Werror=implicit-int -Werror=pointer-arith -Werror=write-strings -Werror=declaration-after-statement -Werror=implicit-function-declaration -Werror=deprecated-declarations -Wno-packed-bitfield-compat -Wsuggest-attribute=noreturn -Wsuggest-attribute=format -pipe | |
XCFLAGS = -D_FORTIFY_SOURCE=2 -fstack-protector -fno-strict-overflow -fvisibility=hidden -fexcess-precision=standard -DRUBY_EXPORT -fPIE | |
CPPFLAGS = -I/usr/local/opt/libressl/include -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -D_DARWIN_UNLIMITED_SELECT -D_REENTRANT -I. -I.ext/include/x86_64-darwin15 -I/Users/urabe.shyouhei/data/src/ci.ruby-lang.org/ruby/trunk/include -I/Users/urabe.shyouhei/data/src/ci.ruby-lang |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From a22a135574b79c3132e4bc1faf3ec275503b94d7 Mon Sep 17 00:00:00 2001 | |
From: "Urabe, Shyouhei" <[email protected]> | |
Date: Wed, 19 Apr 2017 11:01:51 +0900 | |
Subject: [PATCH] refactor extract binop dispatcher | |
Those opt_something instructions are worth refactoring. They tend to | |
have similar ways of executions. By extracting the common part, | |
generated vm_exec_core function shrinks from 26,816 bytes to 26,256 | |
bytes (according to nm(1)). |