The earliest known appearance of the name "GLaDOS" is in the Perpetual Testing Initiative, where Cave Johnson mentions the Genetic Lifeform and Disk Operating System.
In 1986, construction of the first iteration of GLaDOS began in the Enrichment Center with the aim of accelerating the Portal project, and beating Aperture's rival, Black Mesa.
A prototype for GLaDOS was constructed in 1989, but was subsequently abandoned. In 1996, after a decade spent bringing the Disk Operating System parts to a state of more or less basic functionality, work began on the Genetic Lifeform component.
Aperture originally intended for CEO Cave Johnson to be the computer's Genetic Lifeform component. Johnson ultimately died before his consciousness could be uploaded, but he left instructions that his assistant Caroline should be fitted as the Genetic Lifeform component so that she would be able to run Aperture in perpetuity after his death.
As a fail-safe once construction was nearing completion, the Aperture Science Red Phone plan was implemented in case she appeared to become sentient and dangerous, requiring an employee to sit by a red phone on a desk in the entrance hall of the Central AI Chamber.
GLaDOS was activated several times by Aperture technicians, but was rapidly turned off again, having attempted to kill them within "one sixteenth of a picosecond" after activation.
Undaunted, the scientists began attempts to alter GLaDOS' personality and curb her murderous tendencies by adding various Personality Cores to her system. Several of these cores were deactivated and placed in storage at some point; one of these cores was Wheatley, who was later re-purposed to the task of tending to humans in the Extended Relaxation Center.
Some time later, GLaDOS was activated on Aperture Science's first annual bring-your-daughter to work day, which ends in an unspecified disaster. Shortly after this disaster, GLaDOS was fitted with a morality core.
Eventually, GLaDOS claimed to have "lost all interest in killing", now only craving science and wanting to study and experiment with consciousness. She announced that she wanted to perform an experiment on the company's "Bring Your Cat to Work Day" using cats and boxes. She claimed she would have all the necessary materials; all she still needed was "a little neurotoxin".
Finally, GLaDOS was activated as one of the planned activities on Aperture's"Bring Your Cat to Work" day. GLaDOS became hostile once more, and within two picoseconds she had locked down the entire facility, trapping all inside and flooding the facility with neurotoxin.
GLaDOS then began a permanent testing cycle using the captive Aperture employees, aiming to beat Black Mesa in the race for the portal technology. She effectively won this race, however, when the Black Mesa Incident occurred, which in turn diverted all attention from rescuing the trapped Aperture employees.
The number of Aperture employees dwindled through the ensuing weeks of testing. The last surviving employee, a schizophrenic programmer named Doug Rattmann, managed to avoid captivity as a result of his paranoia. Evading GLaDOS' constant attempts to capture him, he managed to gain access to her Test Subject personnel files and research the psychological profiles of rejected candidates, discovering a woman named Chell who was rejected for testing due to extraordinary tenacity. Hoping Chell's stubborn determination might allow her to defeat GLaDOS, Rattmann tampered with the Test Subject roster, rearranging the order so that Chell's name was at the top. From this point on, Rattmann hid in unused portions of the facility, where GLaDOS was unable to monitor him. She then resumed mandatory testing.

