Ladislav Nevery
Proposed C++ optimization with big speed gains with big objects –
Hi guys
Hi guys
I wana discuss proposed optimization step(optional switch?) to c++
compiller that would make old and new code in some cases...
Loading...
Steven Watanabe
AMDG
On 09/24/2012 03:37 AM, _ wrote:
> Hi guys
>
> Hi guys
>
> I wana discuss proposed optimization step(optional switch...
Loading...
Ladislav Nevery
...The old state of city[1] may need to be
cleaned up. Thus, you would also have
to call city[1].~Skyscapper(), first.
I see this more li...
Loading...
Sebastian Redl
On 25.09.2012 01:36, Ladislav Nevery wrote:
> ...The old state of city[1] may need to be
> cleaned up. Thus, you would also have
> to...
Loading...
Ladislav Nevery
>The user did no such thing. The user decided to create a temporary and
>then move-assign it to the old position.
No the user said let...
Loading...
Cory Nelson
On Tue, Sep 25, 2012 at 7:57 AM, Ladislav Nevery <neuralll@...> wrote:
>>The user did no such thing. The user decided to create a tem...
Loading...
Ladislav Nevery
int a=1;
a=2;
The moment I agreed to assign new value I agreed to old value being lost. This is normal and expected behavior.
If you wana ...
Loading...
Klaim
On Tue, Sep 25, 2012 at 6:26 PM, Ladislav Nevery <neuralll@...> wrote:
> int a=1;
> a=2;
>
> The moment I agreed to assign...
Loading...
Ladislav Nevery
Actually the sample you provided will work without problem.
Since switch works only on first assign(after default constructor)
TextFile text...
Loading...
Klaim
On Thu, Sep 27, 2012 at 12:51 AM, Ladislav Nevery <neuralll@...>wrote:
> Actually the sample you provided will work without problem.
...
Loading...
Ladislav Nevery
optimization was meant to finally provide effective creation of static arrays.
Thats why in your case it will simply not be enabled.
TextFil...
Loading...
Ladislav Nevery
ups here is beter example that actually reflects your case with working optimization enabled.
TextFile textfile[1000]
textfile[1]=TextFile(...
Loading...
Sebastian Redl
On 27.09.2012 00:51, Ladislav Nevery wrote:
> Anyway code logic (opening files etc) in default constructors is BLASPHEMY !
> :D such peopl...
Loading...
Ladislav Nevery
Sorry I was joking :) such default constructors can be skipped
Loading...
Ladislav Nevery
Hmm... Now that I think of it wouldnt skiping optimization for objects having any function call except memset from default constructor solve whole...
Loading...
Lars Viklund
Re: Proposed C++ optimization with big speed gains with big objects –
On Tue, Sep 25, 2012 at 09:26:03AM -0700, Ladislav Nevery wrote:
> int a=1;
> a=2;
>
> The moment I agreed to assign new value I ...
Loading...
Ladislav Nevery
the idea was to enable it just for first initialization. ie we mark array elements last constructor was default one
knowing this we can return ob...
Loading...
Ronan Keryell-3
>>>>> On Wed, 26 Sep 2012 01:47:41 -0700 (PDT), Ladislav Nevery <neuralll@...> said:
Ladislav> Now about how releva...
Loading...
Ladislav Nevery
Interesting idea to make it as a pragma. Thx:)
What got me previously motivated about -fplacement_new_on_first_static_array_assign switch previou...
Loading...
Lars Viklund
On Wed, Sep 26, 2012 at 01:47:41AM -0700, Ladislav Nevery wrote:
> yes state machine will change. ie if you were doing let's say gets(from
&g...
Loading...
Ladislav Nevery
Hmm... Now that I think of it wouldnt skiping optimization for objects having any function call except memset from default constructor solve whole...
Loading...
Jean-Daniel Dupas-2
Le 25 sept. 2012 à 18:26, Ladislav Nevery <neuralll@...> a écrit :
> int a=1;
> a=2;
>
> The moment I agreed to assign ...
Loading...
Ladislav Nevery
Skyscrapper city[1000];
city[1] = Skyscrapper("Empire State Building");
city[1].~Skyscraper(); // release member r...
Loading...
Ladislav Nevery
but I completely understand your cautious approach. And I understand that any change must be thoroughly tested thats Why I actually wana implement...