Does PureBasic insert an identifier in your executables?

Just starting out? Need help? Post your questions and find answers here.
toledo
User
User
Posts: 19
Joined: Thu Jan 14, 2010 8:55 pm

Re: Does PureBasic insert an identifier in your executables?

Post by toledo »

Trond wrote:Sorry about being wrong. It turns VB6 has two different compilers, one that compiles to p-code (and has nothing in common in MS VC++) and one that compiles to native code (which I didn't know about). I bloopered twice in this thread, that's my fault, and I'm sorry.
You say you were wrong and then make it sound like you were right but simply omitted some unnecessary fact. Please just admit when you are "misinformed".
The compiler you "didn't know about" is the only compiler that makes executables in VB6. It's the only type of compiler that any programming language (including PureBasic) uses to make executables. It is not some obscure compiler that noone uses. The "compiler" that you DID know about is not a compiler. It is a parser. It compiles source code to p-code. P-code is not an executable. You do not run p-code. You do not access p-code as a runtime module.
Please don't quote me saying "It compiles source code to p-code". Search engines compile. Databases compile. But that was not what we were talking about when we were talking about compiler was it? That's why computer terminology demands that we don't call databases compilers. It's an unwelcome technicality. When a computer programmer says something is a compiler, he means it produces machine code.
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Re: Does PureBasic insert an identifier in your executables?

Post by Kaeru Gaman »

:roll:
oh... and have a nice day.
User avatar
luis
Addict
Addict
Posts: 3893
Joined: Wed Aug 31, 2005 11:09 pm
Location: Italy

Re: Does PureBasic insert an identifier in your executables?

Post by luis »

:roll:
"Have you tried turning it off and on again ?"
A little PureBasic review
Thorium
Addict
Addict
Posts: 1305
Joined: Sat Aug 15, 2009 6:59 pm

Re: Does PureBasic insert an identifier in your executables?

Post by Thorium »

toledo wrote:
Trond wrote:Sorry about being wrong. It turns VB6 has two different compilers, one that compiles to p-code (and has nothing in common in MS VC++) and one that compiles to native code (which I didn't know about). I bloopered twice in this thread, that's my fault, and I'm sorry.
You say you were wrong and then make it sound like you were right but simply omitted some unnecessary fact. Please just admit when you are "misinformed".
The compiler you "didn't know about" is the only compiler that makes executables in VB6. It's the only type of compiler that any programming language (including PureBasic) uses to make executables. It is not some obscure compiler that noone uses. The "compiler" that you DID know about is not a compiler. It is a parser. It compiles source code to p-code. P-code is not an executable. You do not run p-code. You do not access p-code as a runtime module.
Please don't quote me saying "It compiles source code to p-code". Search engines compile. Databases compile. But that was not what we were talking about when we were talking about compiler was it? That's why computer terminology demands that we don't call databases compilers. It's an unwelcome technicality. When a computer programmer says something is a compiler, he means it produces machine code.
A compiler don't have to produce machine code. The PB compiler generats assembly code. Very close to machine code but it's not exaclty machine code. Java compiles to Java bytecode. Even translating a .ini like textfile to a binary format is called compiling. ^^

If you have VB6 installed, just take a look at the compiler settings. There you can choose one of 2 compilers "nativ code" and "p-code". Of course the p-code compiler produces a executable. It's a interpreter followed by the p-code.
Last edited by Thorium on Thu Jan 21, 2010 1:31 am, edited 1 time in total.
User avatar
luis
Addict
Addict
Posts: 3893
Joined: Wed Aug 31, 2005 11:09 pm
Location: Italy

Re: Does PureBasic insert an identifier in your executables?

Post by luis »

Thorium wrote: A compiler don't have to produce machine code.
And we know it! At least to myself a compiler can produce p-code and I'll call it compiler anyway but ...
toledo wrote: Please don't quote me saying "It compiles source code to p-code".
...
When a computer programmer says something is a compiler, he means it produces machine code.
uh oh. I feel a reply coming. You should have let this die here IMHO, this could escalate into a Kale-ish grade thread. 8)

EDIT: here it comes!
Last edited by luis on Thu Jan 21, 2010 12:19 pm, edited 1 time in total.
"Have you tried turning it off and on again ?"
A little PureBasic review
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Re: Does PureBasic insert an identifier in your executables?

Post by Kaeru Gaman »

WOW! ... what a discussion ...

Image

... when the going gets hoff, the Hoff gets going ...
oh... and have a nice day.
toledo
User
User
Posts: 19
Joined: Thu Jan 14, 2010 8:55 pm

Re: Does PureBasic insert an identifier in your executables?

Post by toledo »

Thorium wrote:A compiler don't have to produce machine code. The PB compiler generats assembly code. Very close to machine code but it's not exaclty machine code. Java compiles to Java bytecode. Even translating a .ini like textfile to a binary format is called compiling. ^^

If you have VB6 installed, just take a look at the compiler settings. There you can choose one of 2 compilers "nativ code" and "p-code". Of course the p-code compiler produces a executable. It's a interpreter followed by the p-code.
As I said...
toledo wrote:Search engines compile. Databases compile. But that was not what we were talking about....It's an unwelcome technicality.
The point was you said I was misinformed when I said VB6 and VC++6 use the same compiler but a different parser. I was right on the money and you keep muddying up the waters to confuse the issue.
Will somebody here (NOT THORIUM) please tell me if any of the following statements are wrong?
1. Parsers produce p-code.
2. P-code is not an executable.
3. Compilers produce machine code, and assemblers produce assembly code (including assembly code typed in line by line).
4. Executables are always machine code.
5. Interpreted programs are generally assembly code or source code but never machine code.
6. Java bytecode is interpreted.
7. Interpreters and compilers are two distinctly different things.
8. Executables produced by Purebasic are not p-code.

And finally, my original statement, the one I was trying to get Thorium to admit I was right on without taking pot shots at me (statement number 9 in this post)...
toledo wrote:MS VB6 and MS VC++6 use the exact same compiler. Only their parsers are different.
Please don't reply Thorium. I'm not going to argue with you anymore.
Last edited by toledo on Thu Jan 21, 2010 9:57 am, edited 2 times in total.
User avatar
Blue Steel
Enthusiast
Enthusiast
Posts: 132
Joined: Wed Aug 31, 2005 4:49 pm
Contact:

Re: Does PureBasic insert an identifier in your executables?

Post by Blue Steel »

ehem... excuse me ..(please don't shoot me.. if i'm way off the mark but) don't VB programs require VBruntime dll's .. isn't that a rather major difference between writting for ANY opf the VB's through out the years.. eg:VB1 run time another for vb2 and another for vb3 etc.. etc...

C++ and purebasic don't other than standard system dll's and libararies which VB also needs..
Currently using PureBasic 4.51(x86)

Image http://www.codingmonkeys.com
Covers many languages including PureBasic
toledo
User
User
Posts: 19
Joined: Thu Jan 14, 2010 8:55 pm

Re: Does PureBasic insert an identifier in your executables?

Post by toledo »

Blue Steel wrote:ehem... excuse me ..(please don't shoot me.. if i'm way off the mark but) don't VB programs require VBruntime dll's .. isn't that a rather major difference between writting for ANY opf the VB's through out the years.. eg:VB1 run time another for vb2 and another for vb3 etc.. etc...

C++ and purebasic don't other than standard system dll's and libararies which VB also needs..
Yes VB programs require the runtime library. In VB1 to VB4, the runtime library was an interpreter. In VB5 and VB6, it's just a regular ordinary library providing extra functions since both VB5 and VB6 compile to machine code. VC++ (at least up to 6) also requires runtime libraries.
Thorium
Addict
Addict
Posts: 1305
Joined: Sat Aug 15, 2009 6:59 pm

Re: Does PureBasic insert an identifier in your executables?

Post by Thorium »

toledo wrote: Will somebody here (NOT THORIUM) please tell me if any of the following statements are wrong?
I don't care if you want me to reply or not. :twisted:
toledo wrote: 1. Parsers produce p-code.
wrong
toledo wrote: 2. P-code is not an executable.
right, but an executable can contain p-code
toledo wrote: 3. Compilers produce machine code, and assemblers produce assembly code (including assembly code typed in line by line).
wrong, assemblers translate assembly code to machine code, which by the way don't have to be a executable to make a executable is the job of the linker
toledo wrote: 4. Executables are always machine code.
wrong, see dotNET
toledo wrote: 5. Interpreted programs are generally assembly code or source code but never machine code.
wrong
toledo wrote: 6. Java bytecode is interpreted.
right
toledo wrote: 7. Interpreters and compilers are two distinctly different things.
right
toledo wrote: 8. Executables produced by Purebasic are not p-code.
right
User avatar
luis
Addict
Addict
Posts: 3893
Joined: Wed Aug 31, 2005 11:09 pm
Location: Italy

Re: Does PureBasic insert an identifier in your executables?

Post by luis »

OK, my take:


1. Parsers produce p-code.

Uhmmm, no, I don't think so. The p-code generation is way down along the line. Parsing is at the top of the chain.


2. P-code is not an executable.

It is executable to a virtual machine of some kind, but it's not directly executable by the cpu. So it depends on what you have in mind and on the definition of executable. After all machine code is interpreted too, by dedicated hardware (the cpu). The opcodes are translated to actions on the data bus, the address bus, actions in the internal logical units, etc.


3. Compilers produce machine code, and assemblers produce assembly code (including assembly code typed in line by line).

Not exactly.
Compilers CAN directly produce machine code yes, but also p-code or assembly code.
Assemblers produce machine code from the assembly code.


4. Executables are always machine code.

See point 2.


5. Interpreted programs are generally assembly code or source code but never machine code.

Ok about "never machine code" in the general acceptance of the interpreter idea (even if some interpreter for machine codes exits, for education purposes or for emulating different hardware, etc). Interpreted languages are generally tokenized and interpreted from that because interpreting every time from the source code would be higly inefficient (you would ned to reparse the source at every iteration for example). See almost all basic interpreters of the past for that. Even the C64 BASIC was tokenized. Some "intepreters" can also go a step further and precompile small chunks of code right before the execution. As often happen there is no simply black and white only.


6. Java bytecode is interpreted.

YES! (or better: it's executed by the java vm, it's code but not of a real existing architecture)


7. Interpreters and compilers are two distinctly different things.

YES! (sometimes the differences tend to blend up to a point, see point 5)


8. Executables produced by Purebasic are not p-code.

YES! PB prodece asm, the fasm produce machine code, the linker produce the executable.
"Have you tried turning it off and on again ?"
A little PureBasic review
toledo
User
User
Posts: 19
Joined: Thu Jan 14, 2010 8:55 pm

Re: Does PureBasic insert an identifier in your executables?

Post by toledo »

This is insane. I think I need to stay away from this forum.
User avatar
luis
Addict
Addict
Posts: 3893
Joined: Wed Aug 31, 2005 11:09 pm
Location: Italy

Re: Does PureBasic insert an identifier in your executables?

Post by luis »

Dind't you ask for this ?
toledo wrote: Will somebody here [crap] please tell me if any of the following statements are wrong?
You got a couple of very nice replies, and tagged them with "This is insane."


But I admit I should have considered you asked this too:
toledo wrote: The reason I asked if PureBasic inserts an identifier is because people who reverse engineer software first find out what compiler was used to build the program. Then they write functions to extrapolate which source code would produce the compiled code. Without identifiers, it's much harder to reverse engineer your software and most people won't even try.
leading us to believe you were concerned by a possible reverse eng. of your code, and then you revealed that was only a plot to make us waste some time replying to that... your true intent was:
toledo wrote: That is exactly it! I don't want people to know I am using basic.
So it's probably my fault to have considered you seriously.


Morover you felt it was nice reply to a person writing this:
Trond wrote:Sorry about being wrong. It turns VB6 has two different compilers, one that compiles to p-code (and has nothing in common in MS VC++) and one that compiles to native code (which I didn't know about). I bloopered twice in this thread, that's my fault, and I'm sorry.
in this way:
toledo wrote: You say you were wrong and then make it sound like you were right but simply omitted some unnecessary fact. Please just admit when you are "misinformed".

toledo wrote:This is insane. I think I need to stay away from this forum.
You need to stay away from anyone having a different point of view.

Cheers!
Last edited by luis on Thu Jan 21, 2010 7:56 pm, edited 1 time in total.
"Have you tried turning it off and on again ?"
A little PureBasic review
c4s
Addict
Addict
Posts: 1981
Joined: Thu Nov 01, 2007 5:37 pm
Location: Germany

Re: Does PureBasic insert an identifier in your executables?

Post by c4s »

toledo wrote:This is insane. I think I need to stay away from this forum.
Just do what is best for you.

But don't forget how excellent PureBasic itself and this extremely helpful forum is. ;)
If any of you native English speakers have any suggestions for the above text, please let me know (via PM). Thanks!
UserOfPure
Enthusiast
Enthusiast
Posts: 469
Joined: Sun Mar 16, 2008 9:18 am

Re: Does PureBasic insert an identifier in your executables?

Post by UserOfPure »

toledo wrote:This is insane. I think I need to stay away from this forum.
Newbies. :roll:
Post Reply