Daisuke Maki tried making all the DT::TZ modules use XS, and in fact
went so far as to turn them into C-based data structures that were
primarily accessed via XS. Strangely, this was also slower and more
memory-intensive than the Perl version.
My next guess was that this had to do with how Perl allocates memory for
each namespace.
So I was thinking I could try to make a single object that could
represent all the timezones, but I was kind of lost momentum while
designing that. sad.
Perhaps somebody can think of a way to do something like this?
my $tz = DateTime::TimeZone->new(
name => ...
aliases => ...
other_required_fields => ...
);
This would mean that we would be creating a single .xs file that has a
hash lookup of timezone names to C structs, and we would be initializing
the object with that data.
--d