Is it possible to use the true hibernate system functionalities of Win 7 and OS X to create a kind of instant switching between the two? Imagine this when reading/writing the sleep images to a quick SATA-3 SSD.
Hibernate-corruption-fix: If this is made possible, make sure that your different partitions are not write-enabled from eachother. (e.g. make it so that Boot Camp Windows 7 cannot write to OS X partition and vice versa). This safety measure should make it impossible for your different systems to corrupt eachother when one is suspended into hibernation.
Edit: I realized that I'm not sure that this is how partitions work on a disk. The hibernated OS X kernel could have references to blocks on the disk which it will continue to write to when it is woken up again. Are disk blocks like these contained within a partition or are they assigned to a partition after they have been written on? Is it different on HDD and SSD? Does this affect the above hibernate-corruption-fix?
Ok let's move on:
Windows 7 already has an option "Hibernate" which allows you to boot back to your OS X partition, but OS X does not exactly offer the same.
With OS X it is possible to hibernate by changing the hibernatemode system variable.
Pre OS X 10.7
sudo pmset -a hibernatemode 2
OS X 10.7
sudo pmset -a hibernatemode 25
This makes your Mac go into hibernate when you put it to sleep. You can put it to sleep with:
sudo shutdown -s now
Ok, so far so good. So we can put both Windows 7 and OS X Lion into hibernation at will. But wait! There's more problems up ahead.
When you put OS X into hibernate it will automatically boot back into OS X when you power your Mac on again. This makes it impossible for us to use it for "hotswitching" between partitions.
If you install rEFIt without rEFItBlesser you will get the rEFIt boot menu after OS X hibernation. On OS X 10.7 Lion however, this does not fully work, instead you get a black screen and have to hard shutdown your Mac. But hey! At least it interrupts the automatic OS X boot, right? Maybe it can be tweaked further from there.
As mentioned on earlier OS X:s the rEFIt boot menu actually does come up after hibernation shutdown + power on. This allows you to e.g. boot your Boot Camp Windows 7 partition instead.
There are problems here as well though. Apparently the OS X partition loses its hibernation flag if you follow this method, which means that the next time you boot into OS X, it will not return from its hibernation state. Instead it will do a clean startup. Why is this?
Does OS X look for the existence of a sleep image to determine wether to wake up from hibernation or to do a clean start or does it have some kind of system variable/flag set?
When Win 7 goes into hibernate it shuts down completely and you can then boot into OS X on startup. On OS X however, hibernate forces you to wake up into OS X. Can you hack this so that you're allowed to select boot partition after OS X hibernates and still be able to return later to OS X and wake it up from its hibernate?
Let's see what we collectively can come up with!