#1 Phantom OS
Posted: Fri Feb 06, 2009 4:42 pm
[quote="TheRegister.co.uk"]It's nine degrees Fahrenheit in Moscow right now. That's the kind of cold that makes a man concentrate on his work so he can keep from remembering that the tears the wind blows out of his eyes will freeze on the side of his face before they hit the ground.
In the middle of this icebox, Dmitry Zavalishin is cooking up a new operating system. He calls it Phantom. Phantom is a different approach on the OS than any other out there, with the primary goal of being immortal. In Phantom, powering off the computer will not cause programs to lose state. They can pick up where they left off as soon as the machine is turned back on.
There are a few obvious uses to this sort of technology - medical, military, and mobile - where automatic state preservation will save the programmer from a lot of mistakes and wasted time. But there's also a possibility that the increased productivity may give Phantom some headway into the commercial server market.
To accomplish this automatic state preservation, Phantom continuously snapshots system memory on to disk. At first glance, that seems like a big synchronization problem: All the programs running should have to pause while the snapshot process reads their internal state. However, if you design the operating system around this goal, the process isn't that intense. The fundamental competency of Phantom is creating this snapshot cheaply, without disturbing current processes.
As a side effect of this design principle, Phantom's programming model is different from what developers are used to. To store persistent data in something like Windows or Linux, you need to explicitly write it to a file. Inventing an object serialization scheme can be tricky and error-prone, especially if your object structure is highly connected. Some languages, like Java, provide basic serialization functionality, but in complicated programs, you still need to remember exactly what state needs to be persisted through invocations of the code.
For example, in something like Microsoft Word, you can't just save the user's document to disk. You have to know whether they checked the “bother me every four seconds with helpful hints" or freeze the system for thirty seconds while you launch a help program when I press the button by accident" preference boxes. All that has to go to a file as well.
Because of this different line of thinking, Phantom doesn't have files. Well, there are no files in the sense that a developer opens a file handle, writes to it, and closes the file handle. From the user's perspective, things still look familiar – a desktop, directories, and file icons. But a file in Phantom is simply an object whose state is persisted. You don't have to explicitly open it. As long as your program has some kind of reference to that object, all you need to do is call methods on it, and the data is there as you would expect. That's definitely an advantage in an unstable environment.
All of this sounds neat, but the astute nerd will object: "But you have to re-write all of your code for this Phantom thing. Seems like a waste of time to me." Possibly. Programming has come a long way since the days of the Segmentation Fault and the Bus Error. We have efficient virtual machines now, with write-once-run-anywhere functionality. Java, C#, Ruby, and even languages that don't suck - like Python - support this.
Phantom will target these VM-based languages so that you won't have to rebuild any code. However, it may not be as simple as just copying over bytecode, a developer may have to modify the code a bit to take real advantage of Phantom's "timeless" feature. Old code should still work fine. It would just be inefficient if it does a lot of file I/O.
The Phantom OS is still very much in development. Currently, it will boot on a computer, run programs and perform its state-preservation-to-disk magic trick. Cross-development tools are also in production, to automate porting code.
Still to be done is the GUI. You know as well as I: All that matters in this life is a good command line. Still, the daily-user type needs some sort of mouse. Sounds like a crutch if you ask me.
After the GUI, the next step for Dmitry Zavalishin is marketing Phantom. The best code in the world doesn't mean anything if nobody's buying. Actually, this step has already began, with Zavalishin telling the world that unlike Linux, Phantom is better than Windows.
"You can not compete with Windows, repeating it," Zavalishin says. "It is impossible to compete with Windows, creating a functionally weaker system, such as Linux." (This works best if you read it to yourself with an assertive, Slavic accent). Phantom, he says, will increase programmer productivity by at least 30 per cent - and perhaps as much as 400 per cent.
He likens this to the benefit of VM-based languages. "Growth in productivity from a simple shift in the development of C++ software programming language to Java and C# languages is estimated by experts to be as much as 500 per cent – as, indeed, it explains the displacement of the first language by the last two over quite short period of time."
Nonetheless, breaking into a market is no easy task. The mobile space, one of the markets Phantom will target, is dominated by the iPhone. "iPhone has strong brand name and it is difficult to surpass it technologically,â€
In the middle of this icebox, Dmitry Zavalishin is cooking up a new operating system. He calls it Phantom. Phantom is a different approach on the OS than any other out there, with the primary goal of being immortal. In Phantom, powering off the computer will not cause programs to lose state. They can pick up where they left off as soon as the machine is turned back on.
There are a few obvious uses to this sort of technology - medical, military, and mobile - where automatic state preservation will save the programmer from a lot of mistakes and wasted time. But there's also a possibility that the increased productivity may give Phantom some headway into the commercial server market.
To accomplish this automatic state preservation, Phantom continuously snapshots system memory on to disk. At first glance, that seems like a big synchronization problem: All the programs running should have to pause while the snapshot process reads their internal state. However, if you design the operating system around this goal, the process isn't that intense. The fundamental competency of Phantom is creating this snapshot cheaply, without disturbing current processes.
As a side effect of this design principle, Phantom's programming model is different from what developers are used to. To store persistent data in something like Windows or Linux, you need to explicitly write it to a file. Inventing an object serialization scheme can be tricky and error-prone, especially if your object structure is highly connected. Some languages, like Java, provide basic serialization functionality, but in complicated programs, you still need to remember exactly what state needs to be persisted through invocations of the code.
For example, in something like Microsoft Word, you can't just save the user's document to disk. You have to know whether they checked the “bother me every four seconds with helpful hints" or freeze the system for thirty seconds while you launch a help program when I press the button by accident" preference boxes. All that has to go to a file as well.
Because of this different line of thinking, Phantom doesn't have files. Well, there are no files in the sense that a developer opens a file handle, writes to it, and closes the file handle. From the user's perspective, things still look familiar – a desktop, directories, and file icons. But a file in Phantom is simply an object whose state is persisted. You don't have to explicitly open it. As long as your program has some kind of reference to that object, all you need to do is call methods on it, and the data is there as you would expect. That's definitely an advantage in an unstable environment.
All of this sounds neat, but the astute nerd will object: "But you have to re-write all of your code for this Phantom thing. Seems like a waste of time to me." Possibly. Programming has come a long way since the days of the Segmentation Fault and the Bus Error. We have efficient virtual machines now, with write-once-run-anywhere functionality. Java, C#, Ruby, and even languages that don't suck - like Python - support this.
Phantom will target these VM-based languages so that you won't have to rebuild any code. However, it may not be as simple as just copying over bytecode, a developer may have to modify the code a bit to take real advantage of Phantom's "timeless" feature. Old code should still work fine. It would just be inefficient if it does a lot of file I/O.
The Phantom OS is still very much in development. Currently, it will boot on a computer, run programs and perform its state-preservation-to-disk magic trick. Cross-development tools are also in production, to automate porting code.
Still to be done is the GUI. You know as well as I: All that matters in this life is a good command line. Still, the daily-user type needs some sort of mouse. Sounds like a crutch if you ask me.
After the GUI, the next step for Dmitry Zavalishin is marketing Phantom. The best code in the world doesn't mean anything if nobody's buying. Actually, this step has already began, with Zavalishin telling the world that unlike Linux, Phantom is better than Windows.
"You can not compete with Windows, repeating it," Zavalishin says. "It is impossible to compete with Windows, creating a functionally weaker system, such as Linux." (This works best if you read it to yourself with an assertive, Slavic accent). Phantom, he says, will increase programmer productivity by at least 30 per cent - and perhaps as much as 400 per cent.
He likens this to the benefit of VM-based languages. "Growth in productivity from a simple shift in the development of C++ software programming language to Java and C# languages is estimated by experts to be as much as 500 per cent – as, indeed, it explains the displacement of the first language by the last two over quite short period of time."
Nonetheless, breaking into a market is no easy task. The mobile space, one of the markets Phantom will target, is dominated by the iPhone. "iPhone has strong brand name and it is difficult to surpass it technologically,â€