Performance testing can serve different purposes. It can demonstrate that the system meets performance criteria. It can compare two systems to find which performs better. Or it can measure what parts of the system or workload cause the system to perform badly. In the diagnostic case, software engeineers use tools such as profilers to measure what parts of a device or software contribute most to the poor performance.
In performance testing, it is often crucial (and often difficult to arrange) for the test conditions to be similar to the expected actual use.