  Results are presented from a search for new physics in high-mass diphoton
events from proton-proton collisions at $\sqrt{s}$ = 13 TeV. The data set was
collected in 2016-2018 with the CMS detector at the LHC and corresponds to an
integrated luminosity of 138 fb$^{-1}$. Events with a diphoton invariant mass
greater than 500\GeV are considered. Two different techniques are used to
predict the standard model backgrounds: parametric fits to the smoothly-falling
background and a first-principles calculation of the standard model diphoton
spectrum at next-to-next-to-leading order in perturbative quantum
chromodynamics calculations. The first technique is sensitive to resonant
excesses while the second technique can identify broad differences in the
invariant mass shape. The data are used to constrain the production of heavy
Higgs bosons, Randall-Sundrum gravitons, the large extra dimensions model of
Arkani-Hamed, Dimopoulos, and Dvali (ADD), and the continuum clockwork
mechanism. No statistically significant excess is observed. The present results
are the strongest limits to date on ADD extra dimensions and RS gravitons with
a coupling parameter greater than 0.1.
