Passage: Westminster Hall, the oldest existing part of the Palace of Westminster, was erected in 1097 by King William II ('William Rufus'), at which point it was the largest hall in Europe.  The roof was probably originally supported by pillars, giving three aisles, but during the reign of King Richard II, this was replaced by a hammerbeam roof by the royal carpenter Hugh Herland, "the greatest creation of medieval timber architecture", which allowed the original three aisles to be replaced with a single huge open space, with a dais at the end. The new roof was commissioned in 1393. Richard's architect Henry Yevele left the original dimensions, refacing the walls, with fifteen life-size statues of kings placed in niches. The rebuilding had been begun by King Henry III in 1245, but by Richard's time had been dormant for over a century. In Westminster Hall, the favourite heraldic badge of Richard II—a white hart, chained, and in an attitude of rest—is repeated as many as eighty-three times, without any of them being an exact counterpart of another.Westminster Hall has the largest clearspan medieval roof in England, measuring 20.7 by 73.2 metres (68 by 240 ft). Oak timbers for the roof came from royal woods in Hampshire and from parks in Hertfordshire and from that of William Crozier of Stoke D'Abernon, who supplied over 600 oaks in Surrey, among other sources; they were assembled near Farnham, Surrey, 56 kilometres (35 mi) away. Accounts record the large number of wagons and barges which delivered the jointed timbers to Westminster for assembly.Westminster Hall has served numerous functions. Until the 19th century, it was primarily used for judicial purposes, housing three of the most important courts in the land: the Court of King's Bench, the Court of Common Pleas and the Court of Chancery. In 1875, these courts were amalgamated into the High Court of Justice, which continued to meet in Westminster Hall until it moved to the Royal Courts of Justice in 1882. In addition to regular courts, Westminster Hall also housed...

Question: What was the purpose of the house prior to the 19th century?
judicial purposes