Forum: Ruby-core [ruby-trunk - Bug #7474][Open] I am getting undefined symbol: rb_enable_interrupt when running event

Posted by sam.saffron (Sam Saffron) (Guest)
on 2012-11-30 02:28
(Received via mailing list)
Issue #7474 has been reported by sam.saffron (Sam Saffron).

----------------------------------------
Bug #7474: I am getting undefined symbol: rb_enable_interrupt when 
running event machine
https://bugs.ruby-lang.org/issues/7474

Author: sam.saffron (Sam Saffron)
Status: Open
Priority: Normal
Assignee:
Category:
Target version: 2.0.0
ruby -v: 2.0


I would like to cross report

https://github.com/eventmachine/eventmachine/issues/389

Clearly this breakage could be "on purpose" not sure who should be 
fixing it.
Posted by Nobuyoshi Nakada (nobu)
on 2012-12-21 13:20
(Received via mailing list)
Issue #7474 has been updated by nobu (Nobuyoshi Nakada).

Category set to core
Status changed from Open to Assigned
Assignee set to kosaki (Motohiro KOSAKI)

It's been static since r32510.
I'm not sure if it is a part of public API.
----------------------------------------
Bug #7474: I am getting undefined symbol: rb_enable_interrupt when 
running event machine
https://bugs.ruby-lang.org/issues/7474#change-34937

Author: sam.saffron (Sam Saffron)
Status: Assigned
Priority: Normal
Assignee: kosaki (Motohiro KOSAKI)
Category: core
Target version: 2.0.0
ruby -v: 2.0


I would like to cross report

https://github.com/eventmachine/eventmachine/issues/389

Clearly this breakage could be "on purpose" not sure who should be 
fixing it.
Posted by kosaki (Motohiro KOSAKI) (Guest)
on 2012-12-21 17:15
(Received via mailing list)
Issue #7474 has been updated by kosaki (Motohiro KOSAKI).

Status changed from Assigned to Feedback

> It's been static since r32510.
> I'm not sure if it is a part of public API.

vm_core.h is definitely internal api place.
Moreover rb_disable_interrupt() is wrong api and we may be removed 
later.
There are two problems:

1)

rb_disable_interrupt()
..
rb_enable_interrupt()

is expand to

    sigfillset(&mask);
    pthread_sigmask(SIG_SETMASK, &mask, NULL);

   ...

    sigemptyset(&mask);
    pthread_sigmask(SIG_SETMASK, &mask, NULL);


See? rb_enable_interrupt() ignore old sigmask and set signal mask to 
empty.


2) thread unsafe

pthread_sigmask() only change current thread sigmask. then other thread 
still be able to
be interrupted by signal. then, this api only work single thread 
context. MRI only use this
api when process creation time.


So, I have a question. Why do event machine need rb_disable_interrupt()? 
If I understand correctly,
event machine don't have single thread guarantee.

----------------------------------------
Bug #7474: I am getting undefined symbol: rb_enable_interrupt when 
running event machine
https://bugs.ruby-lang.org/issues/7474#change-34989

Author: sam.saffron (Sam Saffron)
Status: Feedback
Priority: Normal
Assignee: kosaki (Motohiro KOSAKI)
Category: core
Target version: 2.0.0
ruby -v: 2.0


I would like to cross report

https://github.com/eventmachine/eventmachine/issues/389

Clearly this breakage could be "on purpose" not sure who should be 
fixing it.
Posted by kosaki (Motohiro KOSAKI) (Guest)
on 2013-01-29 22:31
(Received via mailing list)
Issue #7474 has been updated by kosaki (Motohiro KOSAKI).

Status changed from Feedback to Rejected

No response. I'll close this then.

----------------------------------------
Bug #7474: I am getting undefined symbol: rb_enable_interrupt when 
running event machine
https://bugs.ruby-lang.org/issues/7474#change-35707

Author: sam.saffron (Sam Saffron)
Status: Rejected
Priority: Normal
Assignee: kosaki (Motohiro KOSAKI)
Category: core
Target version: 2.0.0
ruby -v: 2.0


I would like to cross report

https://github.com/eventmachine/eventmachine/issues/389

Clearly this breakage could be "on purpose" not sure who should be 
fixing it.
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.