Hi Guys

Someone have the BNF - Bacchus Naur Notation algoritm in asm ? (Or even in C or C++ to be translated) ?

This notation works to identify parameter types, calling conventions, etc on C or C++ name mangling syntaxes. The syntax is written in extended Bacchus Naur notation.

Someone have an algoright or function related, that can be able to calculate it ?


Best Regards,

Guga
Posted on 2005-09-08 14:05:12 by Beyond2000!
I dont understand what you are asking ;).. some like http://cui.unige.ch/db-research/Enseignement/analyseinfo/SQL7/BNFindex.html or http://cui.unige.ch/db-research/Enseignement/analyseinfo/BNFweb.html ????
Posted on 2005-09-08 21:52:33 by rea
Hi Rea...

Tks ;)


It is this indeed
http://cui.unige.ch/db-research/Enseignement/analyseinfo/BNFweb.html


What im looking for is some document that can explain any relatino of the BNF notatino form with the C++ (M$, Borland, GCC, Intel) mangling names.

When the compiler decorate the functions names, it uses an extended version of BNF.

Vortex provided this link:
http://www.agner.org/assem/calling_conventions.pdf

For calling conventions and decorated names. On the document it displays several tables on how the function names are mangled in several different compilers, and also says that they uses a extended version of the BNF notation to do the mangling scheme

What im trying to figure it out is exactly how the BNF works, or also see if there is some general example (In asm - or perhaps, in C that can be ported) for a name unmagnler im trying to build.

There are several tables that are responsable for the name mangling, and with several different contents on each. So, to fully understand how the names are decorated will depends on several different combinatinons of the data of the tables.

Since it stated that they uses the BNF, i'm trying to understand how it works, to make the unmangling routines, be less painfull.


Best Regards,

Guga
Posted on 2005-09-09 02:34:20 by Beyond2000!
Hello Guga,

If I am not wrong, BNF is just a notation (It is quite commonly used in some programming question). You would have to write your own parser to extract the information you are seeking.

"BNF is an acronym for "Backus Naur Form". John Backus and Peter Naur introduced for the first time a formal notation to describe the syntax of a given language "

" Since then, almost every author of books on new programming languages used it to specify the syntax rules of the language."

From http://cui.unige.ch/db-research/Enseignement/analyseinfo/AboutBNF.html
Posted on 2005-09-09 02:51:02 by roticv
HI roticv

Yes...im afraid you are right.

It is just a notation. Last year i was in contact with a girl who was doing something like this (And under similar name - BNF  i guess), it was a parser.

I thought that it could be a general algorithm. But, well....

Ill take a look at the document i have for the unmangling tables for the compilers, and see what i can do. Since this is a huge work ahead, ill just try to understand to later we startcoding something about it.

This really sucks.....I wonder why the hell the compilers did never had an agreemenet in using a common decoration scheme, but....no problem.:)

Tks again for the infos.

Best Regards,

Guga
Posted on 2005-09-10 09:42:45 by Beyond2000!