Tuesday, October 1, 2019

Digest for comp.lang.c++@googlegroups.com - 3 updates in 2 topics

David Brown <david.brown@hesbynett.no>: Oct 01 11:26PM +0200

On 01/10/2019 21:25, Bonita Montero wrote:
>> instructions like "leave" are slower than manual expanding the
>> instructions using "pop", "ret", etc.
 
> That's wrong.
 
As a general point, I don't think it is wrong - but from your posting it
looks like it does not apply in the case of "leave". At least, gcc uses
it, which is a reasonable indicator that it is more efficient than
separate instructions.
 
A little googling suggests that the "enter" instruction is slower than
the individual instructions, but that "leave" is quite fast. There are
plenty of other legacy CISC instructions that are slower than breaking
them apart into equivalent simpler instructions, such as the "LOOP"
instructions. I'm sure x86 assembly experts could give you more.
 
I've seen the same thing on other processors too. IIRC, on the 68060
the hardware integer division instruction was slower than a software
division routine.
Anton Shepelev <anton.txt@gmail.com>: Oct 02 12:36AM +0300

Bonita Montero to Anton Shepelev:
 
> > it is.
 
> Most programs use platform-specific means; that's rarely
> an issue.
 
Platform-specific facilities, indeed, are not an issue
because they come with the platform. Some are even
standartised (POSIX), so that general-purpose software can
often be written in largely a platform-independent manner,
e.g. the NetPBM suite and the dcraw developer. Other
programs can be ported to new platform by supplying custom
implementations of the platform-specific functions that they
use.
 
But `alloca()' is not a platform-pecific facility, because
it may exist or be absent on the majority of platforms. Nor
is it a normal, suppliable, dependency because one cannot
simply implement it whenever needed.
 
--
() ascii ribbon campaign -- against html e-mail
/\ http://preview.tinyurl.com/qcy6mjc [archived]
David Brown <david.brown@hesbynett.no>: Oct 01 10:58PM +0200

On 01/10/2019 21:29, Chris Vine wrote:
> criminal offence (to which another poster has now added Polish law). I
> hope for honesty on your part so I assume you have not got around to
> reading any of it.
 
I had not got around to reading it.
 
I am not a lawyer, but it seems I was badly outdated, and certain types
of copyright infringement are criminal offences in their own right,
rather than the crime being in addition to the civil offence of
copyright infringement. Thank you for the correction here. (I am
assuming that other jurisdictions are similar.)
 
As I read the link, simple copyright infringement for personal
non-commercial use is still just a civil matter.
 
But while commercial copyright infringement is a crime, it is not theft
- any more than it is vandalism or another crime. Nor is it piracy.
You received this digest because you're subscribed to updates for this group. You can change your settings on the group membership page.
To unsubscribe from this group and stop receiving emails from it send an email to comp.lang.c+++unsubscribe@googlegroups.com.

No comments: