From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: X-Spam-Status: No, score=-2.9 required=3.0 tests=ALL_TRUSTED,AWL,BAYES_00 shortcircuit=no autolearn=unavailable version=3.3.2 X-Original-To: yahns-public@yhbt.net Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id D4A2A1FAE5; Fri, 5 Jun 2015 17:20:17 +0000 (UTC) From: Eric Wong To: yahns-public@yhbt.net Cc: Eric Wong Subject: [PATCH] reduce inline constant cache overheads Date: Fri, 5 Jun 2015 17:20:15 +0000 Message-Id: <1433524815-20512-1-git-send-email-e@80x24.org> List-Id: We can use symbols in the SleepyPenguin APIs to trade speed for space in uncommon code paths. --- lib/yahns/queue_epoll.rb | 2 +- lib/yahns/sigevent_efd.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/yahns/queue_epoll.rb b/lib/yahns/queue_epoll.rb index 2875920..1511917 100644 --- a/lib/yahns/queue_epoll.rb +++ b/lib/yahns/queue_epoll.rb @@ -15,7 +15,7 @@ class Yahns::Queue < SleepyPenguin::Epoll::IO # :nodoc: QEV_WR = Epoll::OUT | Epoll::ONESHOT def self.new - super(SleepyPenguin::Epoll::CLOEXEC) + super(Epoll::CLOEXEC) end # for HTTP and HTTPS servers, we rely on the io writing to us, first diff --git a/lib/yahns/sigevent_efd.rb b/lib/yahns/sigevent_efd.rb index c65e13f..2c04b36 100644 --- a/lib/yahns/sigevent_efd.rb +++ b/lib/yahns/sigevent_efd.rb @@ -4,7 +4,7 @@ class Yahns::Sigevent < SleepyPenguin::EventFD # :nodoc: include Kgio::DefaultWaiters def self.new - super(0, SleepyPenguin::EventFD::CLOEXEC) + super(0, :CLOEXEC) end def sev_signal -- EW