Return of spinoza1111

N

Nick Keighley

Piet de Arcilla said
The UK libel lawsuit project against Richard Heathfield has been
re- activated. I have not engaged a firm of solicitors as yet but I
shall if his behavior persists [...] although I am
an ordinary person without a lot of financial resources this needs
to go forward.

I find it amusing, however, that he has to appeal to others for help
with the bus fare to the solicitor's office. The law is a game for
rich people to play.

particularly the english libel laws! Legal Aid (state assisted legel
assistance)
won't cover it. I doubt legal insurance would either (insurance
companies
aren't stupid enough of to step into that particular tar pit). So he's
left with either the No Fee No Pay Ambulance Chasers Pro Bono who
tend to prefer big fat companies to sue or rely on Pro Bono. That is
a lawyer who is willing to give his time for nothing.

If he does sue (which won't happen), he will
lose money, I may or may not lose money (depending on whether the
judge awards costs against him for wasting everybody's time), and the
fat cat greedy capitalist lawyers (as he no doubt thinks of them)
will feather their nests nicely.

I can't see where the money is to come from
 
S

spinoza1111

messagenews:[email protected]... [...]
lol. Anyway, some people might compare the type of programming I do
with
"rocket science", or perhaps compare it to juggling running chainsaws.
Well, let's see if you can accomplish a task that I consider to be
fairly
easy. I want to create a reader/writer lock that has wait-free
fast-paths on
both the writer and reader side. I want this lock to be 100%
starvation-free
for both writers and readers. I want bounded time for both readers and
writers. Your not allowed to use CAS. After you accomplish that, I want
you
to augment your algorithm to allow for conditional reader-to-writer
upgrades, and non-conditional writer-reader downgrade. You may use CAS
for
the upgrade/downgrade, but not for reader/writer acquisition or release.
BTW, your not allowed to use any loops in the algorithm. Oh, one more
thing.
I will make it really easy for you in that you do not have to document
any
membars. Once you accomplish this task, then we can begin to discuss
some
more exotic synchronization algorithms...
I'm sorry Chris but I don't feel
Like reinventing another wheel

Creating high-performance reader writer lock is not a waste of time. Heck,
even Sun Microsystems has an entire group working on synchronization
primitives. And guess what? They just released a paper on high-performance
read writer locks. They are using distributed counting technique to increase
scalability. There work in not in vain.
This is not my area of expertise.
You MAY, from where I sit, not be aware that it MAY be impossible to
actually do this on arbitrary platforms. If the lock is a single
instruction on your system in machine language the code isn't portable
to another system.

Actually, my synchronization code is portable to a fairly wide range of
architectures. I know the caveats, and I know how to work around them.

I am unqualified to debate these issues with you at this time. I
studied the subject in graduate school but IMO at the time, the field
of low-level code was too inchoate and inarticulate, with manufacturer
greed and arrogance creating a toxic smog of disinformation.

Everybody seemed to have their own axe to grind, and I could never
tell the difference between a valid technical claim and OEM greed
speaking through a hired hand. I vastly preferred compiler development
since programming language arose like human speech itself, outside
market forces.

But I concede that you have done significant work. My question
remains: was it your talent and genius that did the work, or some
magical property of C? I would say it is the former.
I use a mixture of C and assembly language. C is low-level enough to allow
me to do what I want. Tell me, if I used C sharp, how could I ensure that,
for instance, data is padded to a L2 cache line and aligned on a L2 cache
line boundary? Do you know why that's important wrt synchronization

That seems to this relative layperson pretty silly. It festishizes a
"cache boundary" which is not a law of nature, but the result of
another developer wanting, for a good reason or bad, to do bit shifts
rather than addition or subtraction...I think.

It's absurd to reason from such a specific need to the conclusion that
C is great.
algorithms? Don't get me wrong, C# is a fine language and I do use it from
time to time. But, I can reap much better performance if I use C and ASM to
create synchronization libraries. I can then use that library in C#,
everybody wins.- Hide quoted text -

You need some sociology to go with all those bits and bytes. Critical
theory teaches us that modern society needs for its continued
viability to present a "naturalized" face to the ordinary person.
Social structures which were questioned in the French revolution, in
1830, in 1848 and in the Paris Commune need to be thought of a
"reality", and this is the reason why programmers think inside the
box.

I've never written an OS exclusively in a high level language, but I
believe it's been done. Those efforts fell by the wayside because they
would have in their day commodified mainframes, and this was
unacceptable. Therefore, programmers learned to build in all sorts of
dependencies in their code in order to make it a unique product that
would not interoperate, until Open Source. But by that time, the
damage had been done. Countless architectures had been built around
the quirks of C, for example.

Elvis Costello has a song about the Thatcher era: all this useless
beauty. Much of technology is useless beauty because if we'd done it
right in the first place, there would be no need for all this
Beautiful Code.

A society with a World Government and a World Mainframe running Cobol
would be boring, but would probably feature a three day work week.
Everyone secretly prefers such a fantasy to the one we have which is
in the process of going arse up, in some small part thanks to "new
paradigms" like C without originality that produce much heat but
little light in the long run.

[OK, not Cobol. Some language as yet unwritten. Like mine. Yeah,
right. Well you get the picture: we wanted socialism but like Captain
America and Billy in Easy Rider, we blew it.]

Let me return however to a more technical subject. You are saying
something true GIVEN the existing state of technology: that languages
like C# and Java with a runtime cannot run by themselves without an
underlying codebase that does deep and nasty things in ASM and C.

For C# or Java to work all the way down to the bare metal, the bare
metal would have to be a C# or Java machine perhaps with microcode to
check for type safety, and the "computer designed for the language"
would walk again as it did pre-Risc.

But this means that there's nothing special about C. It was the
madness or the wisdom of a crowd.
 
C

Chris M. Thomasson

I'm not worthy! I;m not worthy!

I know that your a smart guy and will probably be able to progressively
catch on. Although, some REALLY smart people have a hard time getting a grip
on this kind of stuff. Unfortunately, these types of algorithms are not for
everybody. I have been on consulting jobs where peoples eyes glaze over and
they seem like they are spaced out.



Looks like a great stack o' stuff; I will look into it. I use
multithreading only in the most elementary ways.

I think you might be able to use some of these algorithms in the runtime of
your language.



But your accomplishments would have been greater had you used a
language other than C.

You know, I think I am going to have to agree with you on this one. Humm...
Well, luckily I have several fully-self contained examples of some of my
non-blocking queues and my eventcount in C# that you can dive into and play
around with:




http://cpt.pastebin.com/f72cc3cc1
(multi-producer/consumer queue by me /w eventcount by me)


http://cpt.pastebin.com/f52dcc0fc
(single-producer/consumer queue by me /w eventcount by me)


http://heev.pastebin.com/f70a73f00
(multi-producer/single-consumer by Dmitriy V'jukov /w eventcount by me)


http://heev.pastebin.com/f270184be
(multi-producer/single-consumer by Dmitriy V'jukov /w eventcount by me /w
node cache by me)


http://heev.pastebin.com/f10399a09
(multi-producer/single-consumer by Dmitriy V'jukov /w eventcount by me /w
node cache by Dmitriy V'jukov)




I have to admit, coding these algorithms in C# is ___extremely___
convenient. Especially for the first example, which needs a form of tricky
memory management when coded in C/C++. The C# garbage collector takes care
of everything, and its really nice to work with.




Take a look at the C# code before looking at the more raw examples I posted
because I think it will be easier for you to grasp. BTW, these C# programs
are portable to different operating systems and architectures through the
Mono project:

http://www.mono-project.com


This excellent project ported the .NET platform to a lot of new platforms.
Pretty cool!

;^)





Another excellent project was created by my friend Dmitriy V'jukov:

http://groups.google.com/group/relacy


Relacy Race Detector is my personal tool of choice for verifying the
correctness of some of my algorithms. Dmitriy is very smart and has been
interviewed by Intel and the go-parallel team:

http://www.ddj.com/go-parallel/article/showArticle.jhtml?articleID=212903326


he became a black belt member and was interviewed again:

http://software.intel.com/en-us/art...iy-vyukov-intel-black-belt-software-developer



Enjoy!


:^)
 
M

Michael Foukarakis

Let me return however to a more technical subject. You are saying
something true GIVEN the existing state of technology: that languages
like C# and Java with a runtime cannot run by themselves without an
underlying codebase that does deep and nasty things in ASM and C.

<snip>

Oh, they're hardly nasty, or even ugly for that matter. Have you seen
inheritance
and polymorphism implemented in C? Now *that*'s the devil's work right
there. :)

But hey, I love C for the same reasons Mr.Thomasson uses it - which as
you say imply
something about my wit, which I'll snatch as a grand compliment.

I wonder though; if not for C, which high-level language would we use
to satisfy
the need to code on an abstraction level that is sufficiently close to
the machine?
Doesn't the fact that C satisfies that need makes it a good tool for
that purpose?
 
S

spinoza1111

spinoza1111said:



Rather like yours in that respect.


The unstressed syllables matter too. The metre of limericks has never
been fully defined as far as I'm aware, but it should have a rhythmic
"feel" to it. For example, the rhythm of the first two lines and the
last line should be identical. Here's a popular limerick metre (u =
unstressed syllable, / = stressed):

u/u u/u u/u
u/u u/u u/u
u/u u/u
u/u u/u
u/u u/u u/u

Variations on this are possible, of course.

Your "limerick"'s pattern is:
u/u u/u u/u
u/u uu/u u/u
u/u u/
u/u u/
u/u u/u u/

The third and fourth lines, rhythmically speaking, are fine.
Lyrically, they're a bit pants, but then the whole thing is a bit of
a disaster, lyrically speaking. The first line, again considering
only the rhythm, is fine, but the second line is just terrible. Three
consecutive soft syllables on a single limerick line don't work at
all. Finally - sometimes you can get away with skipping a soft
syllable at the start of the line, but dropping a soft syllable from
the /end/ of the fifth line simply doesn't work (or at least, doesn't
work here).


But your limerick didn't make any sense either. Its hostility, on the
other hand, was very clear.

ObC, or at least ObK&R2: I think I'm right in saying that there are no
limericks in K&R2, but there is a little Fitzgerald on offer for
those bored enough to find it.

--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www. +rjh@
"Usenet is a strange place" - dmr 29 July 1999
This line unintentionally left unblank

Richard, this is just nonsense. You're the pub bore who has to be the
authority on everything, and the real authority on certain things has
just walked in to sort you out. You think a Limerick can be writ by
rote and your half-literacy is plain.

Who LIVES in a NorthUMBerland WHEATfield deliberately breaks your rule
while being aware of it because that's the essence of poetry...to know
and break the rules. The implied speaker has nothing but a well-
justified contempt for you, and therefore makes you and the lads wait
for the UMB beat. Poets as opposed to pedants do this all the time.

The poem is meant to be delivered in what you Limeys call a posh
manner, a self-confident drawl as opposed to the clipped anxiety of
the clerkish class.

I considered "who lives in a northern wheatfield" but this implies
that you live in Canada.

And you humorlessly and pedantically reply without writing your own
attempt, showing you to be a fellow, look you, of no wit. As in the
case of C, you know the rules but cannot create. Instead, you try to
destroy people like Navia and Schildt who can.

There is a yob named Heathfield
Who sallies forth enarmit with sword...but no shield
He gets whacked in the head
And is then left for dead
That unfortunate Yob, named Heathfield

There is a glorified Clerk who with clipped Anxiety
Repeats his saws with at best a gloomy Piety
He groans from his Farm
And causes Alarm.
I daresay one should avoid his Society.

In Britain there lives a low programmer
Deficient in wit, hopeless in style, and hapless in grammar:
His name is Dickie Boy
I like with him to Toy
Because he's a vicious little thug and incompetent as a
Programmer.

[Had enough? Then stop bullying people!]
 
S

spinoza1111

I know that your a smart guy and will probably be able to progressively
catch on. Although, some REALLY smart people have a hard time getting a grip
on this kind of stuff. Unfortunately, these types of algorithms are not for
everybody. I have been on consulting jobs where peoples eyes glaze over and
they seem like they are spaced out.

There's a lesson there. Perhaps they think you're a "troll" even if
you aren't.
I think you might be able to use some of these algorithms in the runtime of
your language.

Ah yes: I am working on it during my commute in Victoria Harbor, which
gets rougher and rougher as containership traffic increases and the
harbor is artificially narrowed.
You know, I think I am going to have to agree with you on this one. Humm....
Well, luckily I have several fully-self contained examples of some of my
non-blocking queues and my eventcount in C# that you can dive into and play
around with:

http://cpt.pastebin.com/f72cc3cc1
(multi-producer/consumer queue by me /w eventcount by me)
Thanks.
http://cpt.pastebin.com/f52dcc0fc
(single-producer/consumer queue by me /w eventcount by me)

http://heev.pastebin.com/f70a73f00
(multi-producer/single-consumer by Dmitriy V'jukov /w eventcount by me)

http://heev.pastebin.com/f270184be
(multi-producer/single-consumer by Dmitriy V'jukov /w eventcount by me /w
node cache by me)

http://heev.pastebin.com/f10399a09
(multi-producer/single-consumer by Dmitriy V'jukov /w eventcount by me /w
node cache by Dmitriy V'jukov)

I have to admit, coding these algorithms in C# is ___extremely___
convenient. Especially for the first example, which needs a form of tricky
memory management when coded in C/C++. The C# garbage collector takes care
of everything, and its really nice to work with.

Take a look at the C# code before looking at the more raw examples I posted
because I think it will be easier for you to grasp. BTW, these C# programs
are portable to different operating systems and architectures through the
Mono project:

http://www.mono-project.com

It's interesting that open source tends in the direction of machine
independence, since its programmers don't have to make other people
rich.
This excellent project ported the .NET platform to a lot of new platforms..
Pretty cool!

;^)

Another excellent project was created by my friend Dmitriy V'jukov:

http://groups.google.com/group/relacy

Relacy Race Detector is my personal tool of choice for verifying the
correctness of some of my algorithms. Dmitriy is very smart and has been
interviewed by Intel and the go-parallel team:

http://www.ddj.com/go-parallel/article/showArticle.jhtml?articleID=21....

he became a black belt member and was interviewed again:

http://software.intel.com/en-us/articles/in-conversation-with-dmitriy...

Enjoy!

All this is pretty heady stuff. Thanks.
 
C

Chris M. Thomasson

Chris M. Thomasson said:
[...] [...]
But your accomplishments would have been greater had you used a
language other than C.

You know, I think I am going to have to agree with you on this one.
Humm... Well, luckily I have several fully-self contained examples of some
of my non-blocking queues and my eventcount in C# that you can dive into
and play around with:

You know, its a shame I did not try and code as many of my inventions as I
can in C#. I only did a few of them. Unfortunately, I cannot port all of my
stuff to C# because of some technical issues. For instance, C# does not have
DWCAS (Double-Width Compare-and-Swap). However, I promise that I will try to
port more and more of my stuff to C#, and even Java which incidentally does
have DWCAS.

I think it will open my hard work up to a MUCH wider audience. Coding these
things in C and ASM is like juggling chainsaws, and it can be fairly
tedious. Coding the algorithms that are compatible with C# and Java is a
hell of a lot "easier".

I am also thinking of granting a patent license for my vZOOM algorithm to
open-source non-commercial software only.

[...]
 
L

luserXtrog

On Aug 2, 8:34 pm, (e-mail address removed) (Kenny McCormack) wrote:
...
Creating high-performance reader writer lock is not a waste of time. Heck,
even Sun Microsystems has an entire group working on synchronization
primitives. And guess what? They just released a paper on high-performance
read writer locks. They are using distributed counting technique to increase
scalability. There work in not in vain.
I think you mean: They're work [is] not in vein.
ITYouM: Their (possessive pronoun)

Well, THAT took a while for you brainiacs to get right.

Agreed. Pass around the rouge.
You sure that
C doesn't damage the ability to use a more important language, such as
English?

Importance is a relative, subjective measure. You seem to persist
in conflating such estimations with absolute, objective reality.

The importance of that little exchange is that everyone was nice to
each other, striving for truth. Even if C were all that you claim,
why the fuss? If we are all so braindead as to indulge in such
degrading behavior as to attempt to make use of the C programming
language, how can you expect our debilitated minds to appreciate
the severity of our depravity?

What the real goal here is?
 
S

spinoza1111

On Aug 2, 8:34 pm, (e-mail address removed) (Kenny McCormack) wrote:
...
Creating high-performance reader writer lock is not a waste of time. Heck,
even Sun Microsystems has an entire group working on synchronization
primitives. And guess what? They just released a paper on high-performance
read writer locks. They are using distributed counting technique to increase
scalability. There work in not in vain.
I think you mean: They're work [is] not in vein.
ITYouM: Their (possessive pronoun)
Well, THAT took a while for you brainiacs to get right.

Agreed. Pass around the rouge.
You sure that
C doesn't damage the ability to use a more important language, such as
English?

Importance is a relative, subjective measure. You seem to persist
in conflating such estimations with absolute, objective reality.

It's amazing that technicians can be so utterly dogmatic on their
choice of language yet as regards the humanities and natural language,
regard issues as "subjective"...especially because since the 17th
century and the dawn of the modern era, "subjective" and "objective"
have reversed meaning: "subjective" used to mean that "man is the
measure of all things" and able, indeed required, to make valid
judgements, while "objective" meant uninterpreted facts: today,
"subjective" means something approximately like they say in the Army,
that "opinions are like assholes, everyone's got one"...a stance which
makes it impossible for judgement to trump force and its enabler,
*schlamperei*, going along to get along.

It's far more sensible to judge that there is a reality in important
matters, because absent this willingness to judge, the unused facility
of judgement finds refuge in formalistic mathematics such as suduko or
meaningless programming horseshit.

As human beings we judge. But modern society tells us we should not
judge, and that opinions are like assholes: one's opinion is just as
good as any other, so the local loudmouth (such as Heathfield) gets
his thug way. So, programmers take refuge in an apolitical praxis in
which they can judge without interference, their natural instinct
being thwarted.
The importance of that little exchange is that everyone was nice to
each other, striving for truth. Even if C were all that you claim,
why the fuss? If we are all so braindead as to indulge in such
degrading behavior as to attempt to make use of the C programming
language, how can you expect our debilitated minds to appreciate
the severity of our depravity?

What the real goal here is?

- Show quoted text -- Hide quoted text -

- Show quoted text -
 
L

luserXtrog

...if over-edited, I not being a prestigious chap. Thanks for reading
the abbreviated letters, however. I'd say the fact that I have passed
the editorial bar, which is set high at our mutual newspaper (a
prestigious world paper of record), along with the fact that I've
published articles and a book should give you pause before you make
certain assumptions that are made by others.


I believe I do.





This is NOT the case.

You see, people see what's being said about them and their instinct is
to defend themselves, perhaps with equal force if hopefully with no
fraud. But as I have said elsewhere, other posters don't see the
sequence of events, and very often confuse a person vigorously
defending herself with the attacker, since they read a couple of
recent posts and jump to conclusions.

Furthermore, corporate life makes people less brave and less apt to
defend themselves, thus a vigorous self defense against a nasty,
enabling and/or snide comment, of the sort that Heathfield specializes-
in, seems like bad behavior. But note that the US Constitution, the
oldest written constitution in the world, recognizes the need of men
to have freedom of speech so as to defend themselves...whether against
"noble lords" or their bully boys makes no difference.





The dictionary is a poor guide to the meaning of words. Most truly
literate people learn vocabulary from reading books other than the
dictionary, for the lexicographer reports either his personal
understanding (as did Samuel Johnson in his Dictionary), or general
received usage, which is often just wrong, and lowest-common-
denominator in terms of insight.

Overt gay-bashing "homophobia" might be what the dictionary reports.
However, it is not the lexicographer's job to do social science, nor
to theorize that homophobes may be ordinary thugs enforcing norms
which society needs to enforce as a whole...but which the more genteel
are loth to enforce themselves. Homophobia may be a special case of a
common male inability to relate, connect and talk about feelings
EXCEPT in cases of war and stress under the buddy system.

The term for this is 'bigotry'. You are guilty of synecdoche.
 
S

spinoza1111

spinoza1111said:



FCOL. If you don't believe me, check it out in a poetry newsgroup.

Wow, such a FONT of information that would be. What next? One of those
online poetry contests?

There is a fella named Dickie
Who gets his info 'bout Poetry
From fools in newsgroups
Who are as he be the dupes
Of companies that take his mon-nee!

Jose Ortega y Gasset
Practically blew himself a gasket
Thinking of the revoltin' masses:
The reign of boors, and bullies, and asses
But this the Internet sure surpasses!

Richard Heathfield fancies himself an Authority
On all things, from programming to Poetry.
But alas we see
From prosody to C
He's as wrong as wrong can be!
 
S

spinoza1111

Chris M. Thomasson said:
[...] [...]
But your accomplishments would have been greater had you used a
language other than C.
You know, I think I am going to have to agree with you on this one.
Humm... Well, luckily I have several fully-self contained examples of some
of my non-blocking queues and my eventcount in C# that you can dive into
and play around with:

You know, its a shame I did not try and code as many of my inventions as I
can in C#. I only did a few of them. Unfortunately, I cannot port all of my
stuff to C# because of some technical issues. For instance, C# does not have
DWCAS (Double-Width Compare-and-Swap). However, I promise that I will try to

I can Interchange a 64 bit Long as an atomic operation in the current
free release of C Sharp "express":

System.Threading.Interlocked.Exchange(ref lngValue, lngValue2);

Is this what you mean?

I can do this with double precision values in addition to Longs.

Is this what you mean?

I can even do this with reference objects using generics.

Is this what you mean?
port more and more of my stuff to C#, and even Java which incidentally does
have DWCAS.

I think it will open my hard work up to a MUCH wider audience. Coding these
things in C and ASM is like juggling chainsaws, and it can be fairly
tedious. Coding the algorithms that are compatible with C# and Java is a
hell of a lot "easier".

I am also thinking of granting a patent license for my vZOOM algorithm to
open-source non-commercial software only.

[...]
 
S

spinoza1111

The term for this is 'bigotry'. You are guilty of synecdoche.

Whoa, cowboy. You're saying that to oppose bigotry in a general form,
an inability to relate and a tendency to exclude, is bigotry.

But that would mean that one could never object to bigotry. How nice
for bigots. They only have to start whining about "reverse
discrimination".
 
S

spinoza1111

spinoza1111wrote:

so you cannot tell a compliment from an offense. good shot boy.

Hey, thanks for pointing that out. MY BAD. I so seldom get anything
but shit sometimes I don't see someone saying something nice. I
apologize quite sincerely to the poster above! I thought he was merely
spinning tales about Wacks I've Known, but I didn't see where he
conceded that at a minimum I'm a Wack what can write literate prose.
 
S

spinoza1111

Piet de Arcilla said
The UK libel lawsuit project against Richard Heathfield has been
re- activated. I have not engaged a firm of solicitors as yet but I
shall if his behavior persists [...] although I am
an ordinary person without a lot of financial resources this needs
to go forward.

I find it amusing, however, that he has to appeal to others for help
with the bus fare to the solicitor's office. The law is a game for
rich people to play.

particularly the english libel laws! Legal Aid (state assisted legel
assistance)
won't cover it. I doubt legal insurance would either (insurance
companies
aren't stupid enough of to step into that particular tar pit). So he's
left with either the No Fee No Pay Ambulance Chasers Pro Bono who
tend to prefer big fat companies to sue or rely on Pro Bono. That is
a lawyer who is willing to give his time for nothing.
If he does sue (which won't happen), he will
lose money, I may or may not lose money (depending on whether the
judge awards costs against him for wasting everybody's time), and the
fat cat greedy capitalist lawyers (as he no doubt thinks of them)
will feather their nests nicely.

I can't see where the money is to come from

I'll have a bake sale. I will add giggle weed to the brownies. We'll
all get baked.
 
S

spinoza1111

Piet de Arcilla said
The UK libel lawsuit project against Richard Heathfield has been
re- activated. I have not engaged a firm of solicitors as yet but I
shall if his behavior persists [...] although I am
an ordinary person without a lot of financial resources this needs
to go forward.

I find it amusing, however, that he has to appeal to others for help
with the bus fare to the solicitor's office. The law is a game for
rich people to play.

particularly the english libel laws! Legal Aid (state assisted legel
assistance)
won't cover it. I doubt legal insurance would either (insurance
companies
aren't stupid enough of to step into that particular tar pit). So he's
left with either the No Fee No Pay Ambulance Chasers Pro Bono who
tend to prefer big fat companies to sue or rely on Pro Bono. That is
a lawyer who is willing to give his time for nothing.
If he does sue (which won't happen), he will
lose money, I may or may not lose money (depending on whether the
judge awards costs against him for wasting everybody's time), and the
fat cat greedy capitalist lawyers (as he no doubt thinks of them)
will feather their nests nicely.

I can't see where the money is to come from

I'll stage an international rock and roll festival on Lamma Island.
 
C

Chris M. Thomasson

[...] [...]
But your accomplishments would have been greater had you used a
language other than C.
You know, I think I am going to have to agree with you on this one.
Humm... Well, luckily I have several fully-self contained examples of
some
of my non-blocking queues and my eventcount in C# that you can dive
into
and play around with:

You know, its a shame I did not try and code as many of my inventions as
I
can in C#. I only did a few of them. Unfortunately, I cannot port all of
my
stuff to C# because of some technical issues. For instance, C# does not
have
DWCAS (Double-Width Compare-and-Swap). However, I promise that I will
try to
I can Interchange a 64 bit Long as an atomic operation in the current
free release of C Sharp "express":
System.Threading.Interlocked.Exchange(ref lngValue, lngValue2);
Is this what you mean?
I can do this with double precision values in addition to Longs.
Is this what you mean?
I can even do this with reference objects using generics.
Is this what you mean?

I need to be able to spinoza mutate a reference to an object along with an
integer. In C, the data-structure would look like this for a 32-bit system:


struct anchor64 {
void* ptr; /* assume void* is 32-bits */
int32_t count;
};


static struct anchor64 g_anchor64 = { NULL };


Now, I can use DWCAS (e.g., CMPXCHG8B on IA-32) to atomically mutate
`g_anchor64'.



in a 64-bit system it would look like:

struct anchor128 {
void* ptr; /* assume void* is 64-bits */
int64_t count;
};


There are some "hacks" that I can apply in the 64-bit version in order to
squeeze everything into 64-bit anchor (e.g., pointer packing/compression).
Windows 64 does this with their InterlockedSList API:

http://msdn.microsoft.com/en-us/library/ms684121(VS.85).aspx




In Java this can be accomplished via `AtomicStampedReference':

http://java.sun.com/j2se/1.5.0/docs/api/java/util/concurrent/atomic/AtomicStampedReference.html



Is there an analog of `AtomicStampedReference' in C#? Please try and bear
with be here because I am certainly no expert in C#!


thanks for you help spinoza; I appreciate it. If I can pull this off in C#,
I will be happy!


:^)



port more and more of my stuff to C#, and even Java which incidentally
does
have DWCAS.

I think it will open my hard work up to a MUCH wider audience. Coding
these
things in C and ASM is like juggling chainsaws, and it can be fairly
tedious. Coding the algorithms that are compatible with C# and Java is a
hell of a lot "easier".

I am also thinking of granting a patent license for my vZOOM algorithm
to
open-source non-commercial software only.

[...]
 
C

Chris M. Thomasson

Chris M. Thomasson said:
I need to be able to spinoza mutate a reference to an object along with an
integer. In C, the data-structure would look like this for a 32-bit
system:

Ummm, that should read as:


spinoza, I need to be able to mutate a reference to an object along with an
integer. In C, the data-structure would look like this for a 32-bit system:



Sorry about that.


;^/
struct anchor64 {
void* ptr; /* assume void* is 32-bits */
int32_t count;
};


static struct anchor64 g_anchor64 = { NULL };


Now, I can use DWCAS (e.g., CMPXCHG8B on IA-32) to atomically mutate
`g_anchor64'.
[...]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,996
Messages
2,570,238
Members
46,826
Latest member
robinsontor

Latest Threads

Top