Bash scripting really gets into this. My professor is always harping on us about writing efficient code that will ease work on CPU
Here is a good example of inefficient practices in Linux
http://hacktux.com/bash/script/efficient
Another example I can think of is recursive functions, or functions that continually call themselves until a condition is satisfied. These typically take up a lot of CPU power.