mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* vm_insnhelper.c (vm_call_super_method): remove volatile introduced
in r38365. * vm_insnhelper.c (vm_call_method): use __forceinline to prevent VC to make vm_call_general and vm_call_super_method as the same method. Thanks, Heesob Park. [Bug #7556] [ruby-core:50867] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38377 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
7236046359
commit
1d7f737553
2 changed files with 23 additions and 7 deletions
|
@ -1,3 +1,12 @@
|
||||||
|
Fri Dec 14 16:56:59 2012 Shugo Maeda <shugo@ruby-lang.org>
|
||||||
|
|
||||||
|
* vm_insnhelper.c (vm_call_super_method): remove volatile introduced
|
||||||
|
in r38365.
|
||||||
|
|
||||||
|
* vm_insnhelper.c (vm_call_method): use __forceinline to prevent
|
||||||
|
VC++ to make vm_call_general and vm_call_super_method as the same
|
||||||
|
method. Thanks, Heesob Park. [Bug #7556] [ruby-core:50867]
|
||||||
|
|
||||||
Fri Dec 14 14:59:14 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Fri Dec 14 14:59:14 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* test/ruby/envutil.rb (Test::Unit::Assertions#assert_separately):
|
* test/ruby/envutil.rb (Test::Unit::Assertions#assert_separately):
|
||||||
|
|
|
@ -1556,7 +1556,13 @@ vm_call_bmethod(rb_thread_t *th, rb_control_frame_t *cfp, rb_call_info_t *ci)
|
||||||
return vm_call_bmethod_body(th, ci, argv);
|
return vm_call_bmethod_body(th, ci, argv);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline VALUE vm_call_method(rb_thread_t *th, rb_control_frame_t *cfp, rb_call_info_t *ci);
|
static
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
__forceinline
|
||||||
|
#else
|
||||||
|
inline
|
||||||
|
#endif
|
||||||
|
VALUE vm_call_method(rb_thread_t *th, rb_control_frame_t *cfp, rb_call_info_t *ci);
|
||||||
|
|
||||||
static VALUE
|
static VALUE
|
||||||
vm_call_opt_send(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *ci)
|
vm_call_opt_send(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *ci)
|
||||||
|
@ -1665,7 +1671,13 @@ find_refinement(VALUE refinements, VALUE klass)
|
||||||
static int rb_method_definition_eq(const rb_method_definition_t *d1, const rb_method_definition_t *d2);
|
static int rb_method_definition_eq(const rb_method_definition_t *d1, const rb_method_definition_t *d2);
|
||||||
static VALUE vm_call_super_method(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *ci);
|
static VALUE vm_call_super_method(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *ci);
|
||||||
|
|
||||||
static inline VALUE
|
static
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
__forceinline
|
||||||
|
#else
|
||||||
|
inline
|
||||||
|
#endif
|
||||||
|
VALUE
|
||||||
vm_call_method(rb_thread_t *th, rb_control_frame_t *cfp, rb_call_info_t *ci)
|
vm_call_method(rb_thread_t *th, rb_control_frame_t *cfp, rb_call_info_t *ci)
|
||||||
{
|
{
|
||||||
int enable_fastpath = 1;
|
int enable_fastpath = 1;
|
||||||
|
@ -1852,11 +1864,6 @@ vm_call_general(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *ci
|
||||||
static VALUE
|
static VALUE
|
||||||
vm_call_super_method(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *ci)
|
vm_call_super_method(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *ci)
|
||||||
{
|
{
|
||||||
#ifdef _WIN32
|
|
||||||
volatile int x = 0; /* a workaround to avoid VC++ optimization which
|
|
||||||
makes vm_call_super_method as an alias of
|
|
||||||
vm_call_general! */
|
|
||||||
#endif
|
|
||||||
return vm_call_method(th, reg_cfp, ci);
|
return vm_call_method(th, reg_cfp, ci);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue