Home
 

Friends

About Friends

gaw my gfx card is insane Jul. 24th, 2008 @ 02:19 am
[info]razzlfraz
So I was playing around a bit and unless I made some weird mistake my gfx card supports 2,048 threads!! And this isn't software I'm talking about. This is full blown hardware. Core 2 Duo my ass with your 2 cores. My gfx card has you beat to a pulp! Also, it is one of the lower end gfx cards that support CUDA. The average gfx card's hardware (8600) supports usually 4,096 threads total. geez...

There are complications along the way unfortunately. My 8600 supports up to 512 threads for each core or 'block' and there are 4 blocks on my gpu. Each block has shared memory which sounds wonderful when it comes to threading tasks but ends up being painful when one gets down into the nitty gritty. Let me explain:
There is 16kB of shared memory for all 512 threads. This means that if you're doing any heavy data crunching you're pulling from the global memory which is the vram and is almost exactly 100 times slower. So what can go in the shared memory? i, or a counter can. A var is needed to tell which thread were in the number array it needs to do its math like num3[i]=num1[i]+num2[i]. Without this all threads would do the exact same work and overlap. Ok, so 1 var is needed. No big deal right? 1 32 bit int is 4KB and 16/4 is 4 so you can have 4 different loops going in the 512 threads. This is a hassle because that means each array of numbers is over 100 threads in size. that means numbers over the size unsigned long num[100]. Each num in the array out of 100 can give almost 10 digits so 10*100=1,000 digit numbers. Hopefully, no one in their right mind is adding numbers that size.

There are a couple of different tricks that I can think of in my drugged up half awake state right now: 1) do unsigned short i. i think that is 0 to 255 right? ... 65k I mean. that is 2kB ... 16/2 = 8 which is still a lot. char is 1 so 0 to 255 and umm ... i'm falling asleep as I type this lol... so up to 16 vars for 512 threads. 512/16=32 and num[32] is like almost 300 digit long number which is still pretty damn big.

Another trick I will probably have to do is have an i and a pointer and then put everything into 1 array (like I had already planned on my code that uses the cpu) and do some more math to find out were in the stack such en such is. This is annoying but allows for basically up to 512 individual numbers instead of up to 16 numbers. the problem is i will have mutex problems so lets say i have 100 numbers and 16 i's for loops. how do I go about that? ... gaw annoying.

you'd think they would at least give 1k per thread.

another solution which is tempting but probably a big no no is 8192 registers or 16 registers per thread. Unfortunately, I can't find out the register listing to see what does what but I could possibly dictate one register per num[array] ... gaw but the registers are not shared... fsck.



*goes to sleep* nighty night all ^_^

Jul. 23rd, 2008 @ 09:24 pm
[info]foofers
Just feeling extra in-the-dumps today. Dunno why. Maybe it's being jobless, or the terminally single thing or something like that. I do like dragons though, so here's a picture that summarizes. )

Snowball in Hell Jul. 23rd, 2008 @ 02:07 pm
[info]3catsjackson
Hi there. I've been absent from LJ for a few weeks now, will likely be for a few more, just popping my head in for a sec to mention I'm still alive, just working nearly nonstop.

Many of you are all too used to me complaining about my job, so I thought I'd mention it's actually going fairly well now. Crazy busy, ultra-stressful, all-consuming, but altogether not too bad for That Which Pays The Bills. Major site relaunch hits next week, after which will inevitably come a couple hellish weeks of firefighting. Sometime after that, I look forward to sleeping again.

Meanwhile, don't be offended if I remain LJ-oblivious for a while longer...

C is weird as **** sometimes Jul. 23rd, 2008 @ 03:05 pm
[info]razzlfraz
I learned C++ in college a couple of years ago and I was never taught c but since most of the stuff I do is C based with C++ wrappers I figured I'd learn C. So here I am programming in C and I hit one of the weirdest errors I think I've ever seen. It took me a while to figure out wtf was up.


I have:
#define NUM_THREAD_TASKS ARRAY_SIZE/NUM_THREADS
and in the situation with the error NUM_THREAD_TASKS=10;
I also have int thread which is the number of the thread. In my current test I have 3 threads and the problem happens with the last thread so thread=2; because numbering 0-2 instead of 1-3.

so:
NUM_THREAD_TASKS=10;
thread=2;


if I do:

i=thread*NUM_THREAD_TASKS;
printf("%d\n",i);

the output is 21. 10*2 is 21 !?!?


but get this. If I do:


i=NUM_THREAD_TASKS*thread;
printf("%d\n",i);

the output is 20. 10*2 is 20 !?!?


This is quite the error. It is simple to figure out. Since NUM_THREAD_TASKS is a float and everything else is an int it was bound to get funky eventually. I'll settle for:

i=thread*(int)NUM_THREAD_TASKS;



gaw some problems with programming are a major pain in the ass.





edit: turns out (int) doesn't work when you're doing an equation that deals with pointers. *sighs* I guess I'll go with the NUM_THREAD_TASKS*thread and hope things don't break. if not then i'll make a new var, probably global though because the point was to save memory by using a define. the less vars, the more free memory, and the faster the program runs. that and i plan on porting this code to cuda which is extremely memory restrictive being how small the cache is compared to a normal cpu.

on a random note Jul. 23rd, 2008 @ 12:53 pm
[info]razzlfraz
chopper is the cutest anime character ever ^_^


In the meantime Jul. 22nd, 2008 @ 05:52 pm
[info]lilglenndoggie
Wow i must be bored, im spending more and more time at DA

even posted this

digimon renamon chainsaw anime

Renamon has been drawn doing alot of stuff over the years, but recently i came up with a really crazy story idea that basically reverses the standard digimon plot line about happy go-lucky kids coming to the digital world and having fun advetures. And turned it more into an invasion by fiendish, blood thirsty, kids with ulterior motives.

What the hell is happening to me? Jul. 21st, 2008 @ 04:42 pm
[info]razzlfraz
I use to tease Grandma and call her a 'druggy' cuz of all the prescription stuff she would take. Today I counted what I'm taking and I'm talking more prescription meds than Grandma. Gaw ... i'm only 21 not 65 wtf!?!

I wake up and take 4 different types of meds totaling 9 pills.
In 6 hours I take 2 different types of meds totaling 4 pills.
In another 6 hours right before bedtime I take 5 different types of meds totaling 10 pills.
Then in the middle of the night I can take the same thing I take in the middle of the day since it is suppose to be every 6 hours I take the meds but usually I don't. However, sometimes not taking the meds causes so much pain that it causes me to wake up at night and I take the pills anyways.


So yah... I'm a 'druggie' now. Thank you magical drug Fiorinal!! I'm suppose to take it every 6 hours and without it I'm in so much pain I can hardly sit up. Fiorinal truly is a magical drug. Oh, almost forgot: I was prescribed some high powered anti nausea medicine I'm suppose to take with the Fiorinal but so far I've only taken 2 pills. I don't need it. Also, I was prescribed Vicodin to take with the Fiorinal. For half a week I took it every 4 hours but I realized it just made me not all there and didn't remove much of any pain. After that I stopped taking it. The nausea meds are mainly to be combined with the Vicodin.

Also, I'm not suppose to chew anything. I'm not suppose to smile, frown, talk, or move my mouth much at all. The problem is I'm starving!! I've been on this diet for a week and there is only so much pudding one can take, even if it is one of my fav dessert foods. Today I bought tons of Slim Fast. If I can't eat anything then I'll drink it! So far today I've had a milk shake, 3 cans of slim fast, and string cheese (not sure if I'm allowed to have that, but whatever). What I need to do is find someone who knows what the hell mead is so they can show me some good liquid bread. I don't mind a side effect of being drunk. ;)

So yah......


I don't often post about myself and usually post random funny youtube links and stuff but honestly I'm getting tired it all. I hope this post doesn't bore you.

Yay! Birthday! Jul. 21st, 2008 @ 07:58 pm
[info]ajayav
Okay, so you all know I'll be in Cali for my birthday. I'll give you the updated itinerary and then remind you about the party.

Weds 7/23 - Arrive 2pm, get picked up by Vero, go to chinese bakery because I am fiending for BBQ pork buns!! Hang around and do girly stuff with Vero, then have her drop me off at Tallone's house. Go see Hellboy with Tallone and possibly Jonjon too. (and whoever else wants to join)
Thurs 7/24 - Get the van from my mom's house if I haven't already and go pick up my cousin TJ. Go get my tattoo!! Drop TJ off, then head over to Crack Chicken/Beer.
Fri 7/25 - Drive up to see BossLady, and possibly stop and see MelChan on the way back. Debate whether or not to go up to the City for Meat vs Deathguild at the DNA lounge.
Sat 7/26 -
MY BIRTHDAY!!!! Go for a walk with the Silicon Vally chapter of Team in Training. Stop by the grocery store to get starters for the BBQ. Head over to Maywood park and spend time with friends. Steal my boyfriend off to the hotel and molest him.
Sun 7/27 - Church, lunch and shopping at Trader Joe's with mom, help mom with her open house. Go to karaoke. yay!
Mon 7/28 - Not quite sure what my plans are. My flight leaves at 830pm.

So anyways...PARTY!
Saturday July 26th 11am, Maywood Park, 3330 Pruneridge Ave Santa Clara 95051, Potluck.
Current Mood: chipper

Back on that movie tip Jul. 20th, 2008 @ 07:13 pm
[info]lilglenndoggie
Oh also the Increadables. Defintily the one movie i watch repeatedly, prolly once a month. It never stops kicking ass :O

CUDA Jul. 20th, 2008 @ 03:44 pm
[info]razzlfraz
Anyone know CUDA? http://en.wikipedia.org/wiki/CUDA

If anyone knows the lang I'm thinking about learning it. I was just curious about general input from anyone with first hand knowledge.

Dr. Horrible up only until Midnight Tonight!! Jul. 20th, 2008 @ 03:23 pm
[info]mythos_amante


And Joss Whedon wrote on the FAQ that they will be discussing SOMETHING about it at Comic-Con W00t!

I am in San Diego right now, hanging with my SD family. I love them. It's a good time!

Much love to y'all!

-Tessa
Current Mood: entertained

Can someone explain this to me please? Jul. 19th, 2008 @ 03:53 pm
[info]razzlfraz
On my RSA decryption program I might run a number that takes 14.8 seconds for my computer to decrypt using 2 threads. I have a core 2 duo so obviously using 2 threads is the default set for my computer but if I change it to 1 thread that 14.8 seconds should be about 29.6 seconds right? Instead it is 32.1 seconds to factor the semiprime.

In every situation I try running 2 threads gives more than a 2x speed increase than 1 thread. I didn't think it would be possible to get much over a 1.8x speed increase let alone more than a 2x speed increase.

So does anyone know why this happens? Why has adding threads giving such a speed increase? My guess is since the cache is shared (L3 or L2 is it? whatever) the threads can pull from the same memory. This sounds plausible but I'm using fork() and fork makes each thread a 100% different program so 2 threads is really 2 programs running. I am not using global variables so the to 'threads' shouldn't be able to share the same memory even if they wanted to.


*is confused*

Dream (The Prisoner) Jul. 19th, 2008 @ 08:28 am
[info]lilglenndoggie
Holy crap i dreamed i was in that old Brit show "The Prisoner". Me and another inmate were making our grand escape. We had it alllllllllll figured out. Years of planning in the making. First step was getting past the ol bouncing ball of course. He comes down on m'buddy and im hiding in the shadows ready to pounce.

I start stabbing it with sticks then breaking up the pieces and throwing them into it. It absorbs em and im like "oh crap" then it starts to deflate. and im like 8(________) So i proceed to stab it and cut away and free my accomplice.

Then we pull out the motorboat we built and take off like a bat out of hell. Were over shallow waters and alarms start going off guys in boats are chasing us, we come up to a wall of coast guard like security boats and we just keep going full tilt! We hit a good wave and get launced right over em, we almost wipe out but manage to recover, we zig and zag around gun fire and other smaller boats and just keep heading as far away from the island as possible.

We come up to another huge water barrier but it looks like they took their time getting these floating walls into place. Presumably they didnt think anyone would ever get this far. We shoot right thru the perimeter hooting and taunting like madmen. We're FINALLY in actual deep ocean water, our perusers are falling behind. Eventually come up to some kinda shore line and decide its time to ditch the boat. We start talking and end up inside a dam or an area beneath a bridge. Either way soon we're being pursued again and we're running through this concrete labyrinth, not unlike the layout in Portal. And true to that realization we start finding little nooks and gaps between walls and such.

Its at this point that i realize the other guy with me is Gami. I keep getting lucky figuring out which way to go to stay just a few steps ahead of our pursuers. I barely squeeze thru some narrow gaps in the wall and i see light and hear activity up ahead. I round a corner, stumble down some stairs and bash thru some dry wall and find two guys who are obviously escapees themselves drilling and cutting away at the foundation. I call out to gami but i already fear he fell behind.

Sure enough i hear his voice over some P.A. system and he sounds like they drugged him, and he says what you'd expect a captured person to say. Escape is impossible and so on. I talk to the other escapees and they say they've been working their way thru for quite a while.

Gadamn that place was vast :O

RSA decrypter v1 completed - codename project luck :P Jul. 18th, 2008 @ 08:12 pm
[info]razzlfraz
note: doc gave me some meds that get rid/remove the pain from my migraine so I'm doing good. No need to worry! ^_^

So, what do you do when you have a migraine that lasts for almost a week strait, makes it to painful to play video games or just about anything? Program, that is what! -yah i'm a geek ;)

In the last 48 hours I started a program that would decrypt RSA. It seemed like a fun challenge and in the past I wrote a formula that sqrt() instead of mod() -er % thinngy. divided, you know? - and I honestly thought it would perform slower than brute force but after making it and a brute force version back to back at slowest my program is about 300 times faster. However, it averages at 400 to 600 times faster for most rsa number cracking. I'm not going to get into details right now, but so far this project has been a lot of fun.

On day one I wrote most of v1. It was under 1 page in size for the whole program (obviously not including the header files) and was quite simple to write. I was pleased with the results. On day two I was curious about threading. I have a core 2 duo in my comp and my program runs at a max 99.6% cpu out of 200%. wonderful... So I spent at least three hours learning POSIX linux threading stuff but it turns out to be C and not C++ even if I did get most of it working in C++. Geez, even the tutorials said C++. liars! So I looked at wrappers. There are tons of C++ wrappers but none of them stood out and I was in a bad mood spending half my day wasted so i was like, "fuck it" and I searched for unix's fork() command stuff. It is well documented but there are not really any good tutorials I could find. I know what you're thinking, 'fork!?! that isn't productive! you shouldn't use it!' blah blah blah. It ended up working out really well after I gave up on the tutorials and dived into the direct documentation.

So now my program threads and I set a #define NUM_THREADS up default to 2 right now cuz, you know, core 2 duo and I expected a max of a 1.8x increase but instead I got, as far as I can tell, a full blown 2x speed increase! ok, maybe a 1.99999x increase or something but my program is breathing fire right now! ;)


So, anyways, if you've made it this far either you're crazy, bored, or know what the hell I'm talking about. For the latter: If you run osx I can compile you a version if you want to check out. I currently don't have any user input though. the RSA= is a define as well as the brute force number to start. All that is required is osx 10.5.1 or better. Sorry but 10.4 isn't 64-bit and this is a x86_64 program only. Also, I'm to lazy to look it up but if you run linux and know how I can compile it without booting into a linux distro I'd be happy to. still required: 64bit os so 64bit linux. Oh and windows users are out of the loop. Windows, linux, and unix are all fucking crazy retarded when it comes to threads. Windows has its own way of doing it and therefor my program is not cross comptable unless I install a 64 bit win xp or vista and compile it directly on the OS. oh also, did I forget to mention that I'd have to chance most of the program too? not really fun if you ask me. maybe I should have used a universal thread wrapper that works for linux and windows for cross computability. oh well...

yadayadayada Jul. 17th, 2008 @ 04:32 pm
[info]lilglenndoggie
Yanno, when someone asks me what my favorite movie is, i usually say "i cant pick just one. I like different movies for different reasons."

BUT it has occurred to me that The Goonies is by far my most all time favorite movie. Its the ONE MOVIE that will undeniably make you say "Holy shit they dont make em like that anymore." And i dont even say that as a fanatic of any kind ill likely only watch The Goonies maybe once a year, but everytime its just like seeing it for the first time all over again.

I think the one movie i've watched the most repeatedly, lately, is Night of the living dead (the 95 version) and the remake of Dawn of the Dead.

rofl - bush really is a moron Jul. 16th, 2008 @ 11:58 pm
[info]razzlfraz

Jul. 16th, 2008 @ 01:30 pm
[info]foofers
Working with Celluclay is like trying to sculpt with tuna salad.

Jul. 15th, 2008 @ 08:36 am
[info]taurath
New house is awesome! Very very cool.

A bit perturbed at the moment because my brand new phone broke after a slight drop. They told me I'd have to pay the MSRP. It really does kinda suck since they have the best service I've ever had, and for a really good rate. I had them sort of on a pedestal (omg look, great service/etc), but now I'm sort of meh. Fry's didn't have an option for insurance when I signed up. Basically I need to buy a new phone (MSRP is $320, Fry's has it without any discounts for $229). Which sucks. Pretty hard actually.

Also of note, I have no internet yet; landlord needs to cut a tree down in the back yard so they can run the cable line.

Week Thirteen, Day Two: More sketches Jul. 14th, 2008 @ 05:35 pm
[info]mythos_amante

Week Thirteen, Day 2, originally uploaded by Tessaberry.

Good news is I have internet access at the local coffee shop, so I'll be able to get on this week a little bit!

T'gante's a bit of a daredevil.

Current Mood: awake

Insult of the day Jul. 14th, 2008 @ 10:20 am
[info]arlon
( You are about to view content that may not be appropriate for minors. )
Current Mood: pissed off
Top of Page Powered by LiveJournal.com