About | Industry Watch | Learning Curve | Products | Purchase | Search | Testimonials
Home » Industry Watch » The Technological


'i need to make my program run quicker'

<Seeker`> hmm
<Seeker`> i need to make my program run quicker
<gord> y'know all that stuff where you thought 'well that looks like nice code', ruin the niceness and make it quick ;)
<Venko> Nooo :(
<Venko> All that matters is nice code
<Seeker`> I cant think of any ways of making it small / quicker
<Venko> If the code ends up messy you end up with a buggy program when you build upon it or later
<Venko> Windows is proof of this
<Seeker`> this program takes > 1 hour to run
<oly-mk2> whats the program, whats it written in ?
<Seeker`> its written in C
<Seeker`> its difficult to describe what it does quickly
<oly-mk2> aha, just curious not many program take an hour to run :p
<gord> if its taking an hour to run then you prolly can't speed it up, but rather achive the same result but in a completly different way
<Seeker`> gord: I need to use this specific algorithm
<oly-mk2> could thread it or something if using multi core cpus perhaps
<gord> well then you prolly can't really get any more out of it
<Seeker`> gord: And before I applied the improvements I have done, it would have taken ~ 3 hours
<gord> well it looks like its as quick as its gonna go then huh, upgrade your pooter :P
<Seeker`> heh
<Seeker`> oly-mk2: I'm not sure how much threading will help - its not an obviously parallel algorithm
<Seeker`> moo
<popey> that is all
<ubuntuuk-planet> [gogs] What to Expect from Ubuntu 8.04 (Hardy Heron) - http://www.ubuntugeek.com/what-to-expect-from-ubuntu-804-hardy-heron.html
<ubuntuuk-planet> [schwuk] Managing Software Development available on Amazon - http://schwuk.com/articles/2008/1/5/managing-software-development-available-on-amazon
<Seeker`> does using "if(expected_condition) { x; } else {y;}" produce a quicker program than "if(!expected_condition) {y;} else {x;}" due to pipelining?
<stdin> should be the same, I guess it would depend on how the compiler does it
<daubers> evening to all the insomniacs
<Seeker`> lo
<Seeker`> Surely it affects the instruction pipelining
<stdin> yeah, but some optimisation settings may counter that
<Seeker`> how can the compiler reliably know which branch is taken without running the program?
<stdin> depends on the condition, "if(true)" will always be true
<Seeker`> the condition is a computed value, which the compiler wont know
<stdin> it's hard to tell if it does make a difference or not, but I can't see it making a massive one either way
* jerichokb shouldn't be here
<Seeker`> lo
*** juergen_ is now known as be4truth
<popey> lo
* popey farts on gogs
<lessur> Trying to find documentation for the program www-mysql can anyone help?
<antonio__> hi
<oly-> anyone know a good place to get eee pcs thats in stock
<chaddy> pcworld or toys'r'us would be my first places to check, oly-
<oly-> yeah pcwordl does not have any in stock
<oly-> and there is no toysrus near and says on website out of stock
<oly-> amazoin has them at £300 :p
<oly-> i got mine for £220
<oly-> my parents want to buy one so trying to find some where that has them
<chaddy> I'm planning on getting one, but I'm trying to hold off till the fanless ones appear
<chaddy> which I read might not be till April
<oly-> fanless would be cool, but they are after a cheap computer now :p
<chaddy> give them yours and get a fanless one for yourself when they arrive, perhaps?
<Moniker42> how clueless are they?
<Moniker42> you could tell them the new versions have enough jiggabits to run the virtualisation-education software you need for uni/work/school
<oly-> well they are currently using ubuntu, but the computers a bit old and slow
<oly-> so can be a bit frustrating waiting for the computer to catch up alll the time
<oly-> lol, well my girlfriend has claimed mine
<oly-> she thinks its great uses it at work over her high spec desktop a lot of the time
<Dannilion> I think they were £220 in Toys r Us
<oly-> yeah they was thats where i got mine
<oly-> but they seem to be sold out now
<siloko> hi i have just noticed that all the directories in my /root have execute priveledges for everyone - is that the default?
<stdin> siloko: in /root or / ?
<siloko> stdin: in /root
<stdin> probably normal, default permissions for directories is 755
<siloko> stdin: it just seems a bit wierd that's all - and if it's wrong (i.e. some slapdash piece of admin I have done in the past) then I'd like to know so I will change it back . . .
<stdin> it's normal, sudo -H -i  then "mkdir foo;ls -ld foo" gives drwxr-xr-x 2 root root 4096 2008-01-06 12:26 foo/
<siloko> stdin: ok thanks - so if as root i create a bash script in a directory off /root then anyone can execute it - that seems a bit weak . . .
<sdh> siloko: chmod 700 /root and fix your umask
<stdin> files won't be 755, the'll be 644
<siloko> I appreciate I can change it - i'm just saying as a default it seems a little strange . . . (i just created a bash script in a subdir off root and executed it as a normal user with any password request)
<siloko> *without*
<stdin> as long as it's not suid that's not a problem, they can only run the commands as their user
<siloko> true
<siloko> i wonder what the odds that the three people involved in a conversation out of 52 users all chose handles beginning with 's'   (i'll get my coat) . . .
<sdh> :)
<sdh> siloko: it's something i've thought about a lot in the past
<siloko> lol
<sdh> not that
<sdh> lol
<sdh> the permissions thing
<siloko> ok :)
<sdh> i can see some merit to shipping with /root 711 or even 700 but i'm guessing somebody somewhere decided not to
<sdh> ditto for all /home/* actually
<sdh> sudo dpkg-reconfigure adduser
<sdh> "Do you want system wide readable home directories? "
<siloko> I started looking at the permissions when I tried to run a root script from the run dialog (alt-f2)
<siloko> I could run the whole script and that's because there is an anomaly with cached passwords
<siloko> usually if you enter a password for sudo whilst running a particular process - it is cached for that process only (multiple terminals require multiple password entries for example)
<siloko> but it seems that running a script via the run dialog with use *any* cached password (i have tried it with a cached password entered through synaptic and in a terminal . . .) it's a bit wierd and maybe I need to do some more tests to nail it down
<siloko> ***Read 'will' instead of 'with' in the previous bit . .  .***
<siloko> I'm not saying it is insecure (maybe it is) but it is a little inconsistent
<sdh> are you sure it's not related to tty_tickets
<sdh> e.g. https://bugs.launchpad.net/ubuntu/+source/sudo/+bug/87023
<ubotu> Launchpad bug 87023 in sudo "sudo option "tty_tickets" gives false sense of security due to reused pts numbers" [Undecided,Confirmed]
<Nafallo> anyone has anything to say about Maxtor Atlas 15K II?
<jerichokb> afternoon all. anyone alive?
* Moniker42 hides behind a cupboard
<Nafallo> jerichokb: define 'alive' ;-)
<jerichokb> breathing will do
<jerichokb> no need for meaningful brain function, this is #ubuntu-uk, after all...
<Nafallo> oki. I'm alive then.
<jerichokb> come out come out wherever you are, Moniker42
<jerichokb> phew. i thought you might be typing from beyond the grave
<Nafallo> well, there should be fibres burried ;-)
<Nafallo> I wouldn't mind.
<Moniker42> no, i think you're looking for #ubuntu-undead
<Moniker42> those unrelenting geeks that had PCs installed in their coffins
<Moniker42> the idea was to call for help, but no one seems to have bothered...
<jerichokb> i think i saw a multi-media gravestone on engadget a while back
<Nafallo> I'll take an eee with me if I died tommorrow ;-)
<jerichokb> what is it with the eee obsession in here?!
<Nafallo> jerichokb: you haven't got one, have you? :-)
<jerichokb> heh no
<Moniker42> then, get out!
<Nafallo> jerichokb: that would explain your confusion then ;-)
<Moniker42> you're not allowed in here until you have one
<jerichokb> i'll get one for my birthday, is that enough?
<ubuntuuk-planet> [Josh Blacker] jerichokb - http://jerichokb.wordpress.com/2008/01/06/just-unbelievably-cool/
<mistermax> irc://irc.gnome.org/#banshee
*** MrM is now known as mrmonday
*** MrM is now known as mrmonday
<Venko> Britain, Britain, Britain
<Venko> What is it to be British?
<Venko> I pose that question to everyone here
<Venko> What is "Britishness"?, etc.
<elliot__> ?
<Venko> In your own opinion
<jerichokb> it's a state of mind Venko
<jerichokb> if you think you're British, you are. if you don't think you are, you're not.
<Venko> I think I'm British.
<Venko> But that's not what I'm after. Perhaps I phrased my question badly.
<Gary> how am I supposed to know, I was born in Germany :p
<Venko> I'm trying to define what British people are like. Traditions, what people in Britain get up to, etc.
<jerichokb> well it's a difficult question to answer
<Venko> Indeed. I figured the best bet is to ask everyone to contribute :)
<Gary> imho a high proportion don't work and are lazy :p
<sdh> i dont think britain has a real identity any more
<jerichokb> what kind of Britons? white middle class Brits or Asian Britons or working class Britons or...
<Gary> sdh, /me agrees
<sdh> it's become a mash or royal family, media and scum
<sdh> s/or/of/
<Venko> Isn't Gordon trying to get a "British Day" set up to celebrate being British?
<sdh> i'm with gary... to be british is, sadly, to be on the dole reading the sun and having lots of kids
<jerichokb> i don't think we've ever had a real identity, not one that encompasses everyone. the closest we've come is having common enemies: used to be the French, then the Germans in WW 1+2
<sdh> jerichokb: and now we have "terrorism", apparently.
<Gary> you mean we stopped hating the french?
<sdh> heh
<jerichokb> sdh, apparently yes. but it hasn't galvanised the populace like the nazis did
<Venko> Alright then. Lets sort things into different categories
<Venko> Different "types" of British people
<jerichokb> have you read 'White Teeth' by Zadie Smith, Venko?
<Venko> Nope
<jerichokb> it's really good, looks at integration of immigrants into 'Britain'.
<Venko> We're all immigrants though :S
<gord> im not, i was here before all these roman guys, weirdos with their weird camp leaders
<jerichokb> yes, like the Americans
<Venko> It's true, gord is ten thousand years old
<Venko> He's the original Brit
<jerichokb> all hail gord
<sdh> heh
<jerichokb> Venko, there are plenty of people who'd say they're not British anyway, rather just 'English' or Welsh. and even some airy europhiles who'd say european!
<Venko> I say European sometimes...
<Venko> It helps the Americans :P
<gord> i say im gord
<bjwebb> im in this thing called the rest of the world :D
<Venko> In that case we're not British
<Venko> We're gord
<bjwebb> is what you have to say to some amercians
<Venko> Seeing as he's the original
<jerichokb> if we can define gord, we can define Britishness.
<bjwebb> Venko: the correct word is gordish
<gord> i think im gonna move so i can be steve
<sdh> try this http://en.wikipedia.org/wiki/Britishness
<Venko> I looked at that
<Venko> I don't find it helpful
<sdh> http://www.google.co.uk/search?q=%22what+does+it+mean+to+be+british
<sdh> when i think britain, i think tim henman
<sdh> and he sucks :)
<sdh> i liked blur and oasis though
<Venko> :P
<jerichokb> there's nothing like a beer for an irresponsible working environment :)
<ubuntuuk-planet> [Andy Price] Twyt (Reprise) - http://andrewprice.me.uk/weblog/entry/twyt-reprise
About | Industry Watch | Learning Curve | Products | Purchase | Search | Testimonials
Copyright © Rixstep. All rights reserved.