Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Next Apocalypse
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Gordon Henriksen  
View profile  
 More options Sep 19 2003, 9:50 am
Newsgroups: perl.perl6.language
From: malic...@mac.com (Gordon Henriksen)
Date: Thu, 18 Sep 2003 15:33:46 -0400
Local: Thurs, Sep 18 2003 3:33 pm
Subject: RE: Next Apocalypse

chromatic wrote:
> The point is not for module authors to say "no one can ever extend or
> modify this class".  It's for module users to say "I'm not
> extending or modifying this class".

Ah, shouldn't optimization be automatic? Much preferrable to provide
opt-out optimizations instead of opt-in optimizations. C++ const
qualifiers, anybody? final in Java? Compressable line noise in most
programs, those.... Even--especially--programmers who are writing code
in main:: can be naïve of the code they call; they're no more
trustworthy than the module author. It's the local user of a class which
knows what's going on, and not even then in the case of polymorphic
classes. The optimizations enabled by final/sealed are very broadly
applicable to most code; would be good to turn them on by default and
automatically turn them off when they become inapplicable. DWIM +
performance + flexibility. Thus the notifications discussion.

If method call->function call optimization were dicking with a routine
and making it misbehave (e.g., forcing excessive recompilation), though,
I would want to see a plain old pragma to broadly turn off the
optimization. Just:

    no optimized <method_calls>;

That way, I could move the pragma down as far as an unnamed block, if I
wanted to isolate its effects to one method call, or as far out as the
entire module if I was lazy and wanted to do that instead. But no
I-promise-not-to-override-methods-of-this-class-anywhere-in-the-entire-p
rogram pragma for me, thanks. Way too much action at a distance.

Potentially disruptive optimizations, off by default, could be
intuitively enabled by the same pragma, too:

    # Try hard to vectorize hyper arithmetic for SSE and AltiVec.
    use optimized <vector_hyper_ops>;

And it sets up a namespace for optimizations, which might help make
optimizations extensible, transparent, or even pluggable.

--

Gordon Henriksen
IT Manager
ICLUBcentral Inc.
gor...@iclub.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.