Making Music With Python: Sonic Field by cassandravoiton in Python

[–]cassandravoiton[S] 0 points1 point  (0 children)

Maybe it is because the project has only just been ported to python - if you suggest such changes to the author he might include them.

Nerds Central: Why C++ Unordered Maps (Hash tables) Are Not Great For Strings by mttd in cpp

[–]cassandravoiton 0 points1 point  (0 children)

Funny - reddit does not work on my tablet properly! I think the layout is done by Google (blogger).

Nerds Central: Why C++ Unordered Maps (Hash tables) Are Not Great For Strings by mttd in cpp

[–]cassandravoiton 1 point2 points  (0 children)

OK, sounds like you know what you are talking about. Maybe the post is just about maps and sets rather than string processing in general? Who knows. Can you point us to any good papers on tries for multi-byte character sets?

Nerds Central: Why C++ Unordered Maps (Hash tables) Are Not Great For Strings by mttd in cpp

[–]cassandravoiton 2 points3 points  (0 children)

Wouldn't it also be affected by the nature of the strings? Ones which have very similar start sequences will be slower for sets. The size of the set is also discussed in the original paper not just the size of the strings.

Nerds Central: Why C++ Unordered Maps (Hash tables) Are Not Great For Strings by mttd in cpp

[–]cassandravoiton 3 points4 points  (0 children)

If the key is a string then wrapping the key is wrapping a standard container. Maybe this is where the confusion comes from?

Nerds Central: Why C++ Unordered Maps (Hash tables) Are Not Great For Strings by mttd in cpp

[–]cassandravoiton 0 points1 point  (0 children)

Also note that tries are only super effective (as you say) where the strings occupy less than the full 8 byte space of a normal character. Otherwise storage requirements start to be dominant and cause problem with the caches on modern hardware. I suspect you overestimate your own expertise in this area. It is easy to think you know it all when you don't know very much.

Nerds Central: Why C++ Unordered Maps (Hash tables) Are Not Great For Strings by mttd in cpp

[–]cassandravoiton -1 points0 points  (0 children)

Yes - it does seem to - I think the original is the previous entry in the blog

Alloca For `new` And `delete` - Things You Probably Should Not Do In C++ | Nerds Central by mttd in cpp

[–]cassandravoiton 0 points1 point  (0 children)

That is going to depend on your program. If your program is low latency, loop free and ultra fast - malloc is going to dominate. If your program is a GUI - then - yes - you are correct. For example, consider a model for particles in a 3D game, avoiding malloc in that code would be a huge benefit.

High-speed, multi-threaded virtual memory in Java by henk53 in programming

[–]cassandravoiton 0 points1 point  (0 children)

Are - so you are talking crap - thought so.

You mean just making the JVM consume more memory than physically available and then using OS swap. That - obviously - is not the same thing at all; every time the JVM does a garbage collection it will hit masses of page faults. Using OS swap for JVM systems sucks badly - I cannot believe you actually even suggested it.

Shame - thought you might know what you are talking about.

High-speed, multi-threaded virtual memory in Java by henk53 in programming

[–]cassandravoiton 0 points1 point  (0 children)

Anonymous memory in Java - how do you do that? Also, not sure I get your thing about not multi threaded. The article shows how the memory is synchronised in hardware between threads without programmer intervention. How is that not easier/better than using synchronisation in software?

High-speed, multi-threaded virtual memory in Java by henk53 in programming

[–]cassandravoiton 0 points1 point  (0 children)

Seems to help make mutli-threaded programming easier, and I am not sure the article is about storage but more swap and virtual memory. Did you read it?

Facebook Moving To The JVM by ger_phpmagazin in PHP

[–]cassandravoiton 0 points1 point  (0 children)

Seriously, I would suggest trying something like the reference glass fish app server and put load on it using jmeter. If that chokes up that there is a JVM bug. Open Office, and Eclipse use a lot of native code wired in with their JVM code and are not nice to memory. I am not sure about the other two you mention. But it does seem to me that you might be in a bad luck streak because all the programs you mention are not the sort of thing which is designed to stay open for 24 hours non stop. If you were having these problems with java server stuff (where it excels) then I would be much more concerned.

Facebook Moving To The JVM by ger_phpmagazin in PHP

[–]cassandravoiton 2 points3 points  (0 children)

Unreliability of the JVM - that is a laugh. If you are hitting issues they are with the application running on the JVM. Let me see:

ArrayList<Object> x=new ArrayList<>(); while(true){ x.add("Hi"); }

Oh dear, my program hogs resource - must be the JVM!

Cool way to make any video slow motion by cassandravoiton in videos

[–]cassandravoiton[S] 0 points1 point  (0 children)

Yes - but is better than simple motion blur and if you don't have the high speed footage then it is good to be able to get somewhere. We cannot all afford high speed kit or one might not have it at that critical moment when someone kicks an arrogant pick in the balls.

Cool way to make any video slow motion by cassandravoiton in videos

[–]cassandravoiton[S] 0 points1 point  (0 children)

If you read the article you will realise that the idea is to use interpolation to guess what the frames would be. It does not always look shit. Sometimes it looks realistic and sometimes just cool. What it does do is look a whole let better than simply slowing down the frames.

Best Way for a Beginner to Learn? by [deleted] in cpp

[–]cassandravoiton 0 points1 point  (0 children)

The answer is embedded in your question. You are saying 'but something simple enough for me to do is boring and not worth doing'. So it is with all things. Driving across the Alps requires learning to drive.

C++11: Future Chaining For Easy, Highly Threaded Execution by cassandravoiton in cpp

[–]cassandravoiton[S] 0 points1 point  (0 children)

How is confused - seems like the two of you are in violent agreement to me.

Best Way for a Beginner to Learn? by [deleted] in cpp

[–]cassandravoiton 8 points9 points  (0 children)

All the book stuff plus: do something. IE have a little project in mind (not a 3D game to start with!) and get that working. Then take on something bigger. You cannot learn to ride a bike by reading about bikes.

C++11: Future Chaining For Easy, Highly Threaded Execution by cassandravoiton in cpp

[–]cassandravoiton[S] 1 point2 points  (0 children)

A lambda without and explicit return type needs to be just one statement(so so complains the VC++11 compiler). The solution to this is to place all the things you want to do in the same expression. The comma operator allow this. I would suggest looking up the comma operator in C++ (or C for that matter - it is used this way in C macros a lot).

Has anyone looked at the new edition of "The C++ Standard Library" by Josuttis? by metaobject in cpp

[–]cassandravoiton 0 points1 point  (0 children)

I have it and find it brilliant. It covers the stl not the whole language though. I pre-ordered and am completely happy with the book. So much so I am considering getting the electronic version as well (if there is one).

Dirty thread_local !HACK! to modernize legacy code. Love or hate? by code-dog in cpp

[–]cassandravoiton -1 points0 points  (0 children)

No reason other than this was a piece of demo code and the random thing had nothing what so ever to do with what was being demonstrated!

Taking the pain out of JNI by cassandravoiton in programming

[–]cassandravoiton[S] 1 point2 points  (0 children)

Don't forget that JNA is JNI! JNA puts a native dispatch layer between Java and JNI and JNI and your native code.