[pedevel] Re: New nightly build? / ASM keywords

  • From: Christian Packmann <Christian.Packmann@xxxxxx>
  • To: pedevel@xxxxxxxxxxxxx
  • Date: Tue, 16 Mar 2004 16:35:18 +0100

On 2004-03-16 10:24:29 [+0100], BiPolar wrote:
>> [ nightly build ]
>
>Wasn't that "automatic" ? seems not.

Seems to have broken some time ago. I checked the dates again, and I was 
mistaken about the last build - that has a date of late January, not February.

Anyway, if the language plugins are binary compatible to the older BeUnited 
builds, could someone mail me the ASM plugin? I'm currently doing some heavy 
ASM coding, and having syntax highlighting would improve my life 
considerably. 

>> [ list of 3DNow! and SSE instructions ]
>See 
>http://code.beunited.org/cgibin/cvsweb.cgi/pe/Languages/Resources/keywords.asm 

>for what it's there already (and how to split them, specially the user 
>sets).

As I'm too lazy to splice all new commands into the old set manually, I've 
written a small C++ program which merges all the words contained in one or 
more files into one set, according to the format in keywords.asm; output is 
to stdout, duplicate words are eliminated automatically. This still requires 
some manual work, as the program doesn't parse the format of Pe keyword 
files, but it makes updating keyword lists much easier. Source is included at 
end of this mail; I place the source in the public domain, so do with it 
whatever you want.

>I've tried to make it NASM friendly.

Very good. :)

>I would like to say: send it to me, but I'm having problems with my 
>bu.org cvs account (that's why I didn't committed the improved BeBook 
>extension Oliver).

I've put the new keywords.asm up at 
<http://www.uni-mainz.de/~packc000/keywords.asm>, so that anybody interested 
can grab it. It won't stay there permanently, but at least a few weeks.
This version includes all 3DNow!, SSE and SSE2 commands, as well as the PIV's 
new PAUSE instruction.

Bye,
Chris


### wordmerge.cpp #############################
#include <iostream>
#include <fstream>
#include <map>
#include <string>

int main(int argc, char** argv) {
        map<string,int> wordMap;
        map<string,int>::iterator wmIter;
        ifstream infile;
        string s;
        for(int i=1; i<argc; i++) {
                infile.open(argv[i]);
                while(!infile.eof()) {
                        infile >> s;
                        wordMap[s]++;
                }
                infile.close();
        }
        s.erase();
        const int maxLen(80);
        char lastBeginning;
        for(wmIter=wordMap.begin(); wmIter!=wordMap.end(); ++wmIter) {
                if((lastBeginning != wmIter->first[0])
                        || (s.length() + wmIter->first.length() >= maxLen))
                {
                        cout << s << endl;
                        s.erase();
                }
                lastBeginning = wmIter->first[0];
                s.append(wmIter->first);
                s.append(" ");
        }
        if(s.length() > 0)
                cout << s << endl;
        return 0;
}
###############################################

Other related posts: