D is a leading manufacturer in the aerospace and defense markets. D discharged hazardous substances, including trichloroethylene, at its Sacramento site and thereby caused pollution in and around that location as the substances spread onto the ground, into the groundwater, and beyond toward the American River. Ps filed a complaint for declaratory relief regarding the parties' rights and duties under various comprehensive general liability and other insurance policies. Ps sought declarations including that it was not obligated to provide, and D was not entitled to receive either indemnification or defense. D which had been represented by independent counsel since about 1979, filed a cross-complaint for declaratory and other relief against Ps. D filed an amended cross-complaint against 54 insurers, under 245 comprehensive general liability and other insurance policies with periods incepting as early as 1950 and expiring as late as 1984, as to 38 actions. The 38 actions all involved D discharging hazardous substances in an ongoing fashion at its Sacramento site and thereby causing pollution in and around that location resulting in continuous and/or progressively deteriorating bodily injury and/or property damage. The Court of Appeal granted a petition for writ of mandate submitted by D to compel the superior court to vacate an order granting a motion by Ps for summary adjudication of certain issues and to enter a new and different order denying that motion. The superior court had summarily adjudicated that “response costs” under CERCLA, and similar costs under the Porter-Cologne Water Quality Control Act, could not constitute indemnification costs, i.e., expenses to resolve liability, that the insurers had to incur in fulfilling their duty to indemnify. The Court of Appeal concluded to the contrary. It therefore caused the issuance of a peremptory writ of mandate. It did not consider whether costs of this sort could constitute defense costs, i.e., expenses to avoid or at least minimize liability. Following entry of the dismissal without prejudice of the complaint by Ps, the superior court effectively transformed D's cross-action against the insurers into an action in and of itself, ordering D to be designated “plaintiff” and not “cross-complainant” and the insurers to be designated “defendants” and not “cross-defendants.” (we are keeping the designations as P and D). From 1956 to 1984, D had various comprehensive general liability insurance policies. Since 1979, Aerojet had incurred as defense costs “legal” expenses of $5,283,568, and “legal support” expenses of $5,634,149, for a total of $10,917,717; and, toward that amount, the insurers had paid $5,680,367, plus interest. The superior court ruled that site investigation expenses were not defense costs. It also ruled that defense costs could be allocated to the insured. Specifically, “D has held itself out to the world as insured by I.N.A.” under its “fronting” comprehensive general liability insurance policies. The jury returned a unanimous verdict determining that D's site investigation expenses were not defense costs in any part. D appealed. The Court of Appeal affirmed the “final judgment,” the various judgments and orders related thereto, and the order on the taxing of costs. The Court of Appeal concluded that the superior court did not err in ruling that defense costs could be allocated to the insured. It held to this effect: because D agreed that it would pay its own defense costs under the “fronting” comprehensive general liability insurance policies issued by INA from 1976 to 1984, it “should now carry [its] fair share of the burden” pro rata based on the time of noninsurance within the time as a whole. The Court of Appeal denied a petition for rehearing by D. Both parties sought review. The issues to be resolved are whether, under standard comprehensive or commercial general liability insurance policies, site investigation expenses may constitute defense costs that the insurer must incur in fulfilling its duty to defend, and whether, under such policies, defense costs [may be allocated to the insured.