First of all, it's important to note that syllables containing a vowel + gn combination are long (or, less confusingly, "heavy"), regardless of the length of the vowel itself. As Bennet says:
A syllable is long,—
a) if it contains a long vowel; [...]
c) if it contains a short vowel followed by x, z, or any two consonants (5.B.1)
It does not follow, however, that the vowel preceding gn is necessarily long. For that, we'll need to turn to other sources.
W. Sydney Allen addresses the matter in Vox Latina, 71ff:
It is commonly, and mistakenly, believed that vowels in Latin are regularly long before the consonant-group gn.
Allen contends that:
- The "rule" rests on a single passage in Priscian
- The passage in Priscian is an interpolation, not original
- Historical evidence frequently contradicts the rule
- Only a few words—rēgnum, stāgnum, sēgnis, and abiēgnus—are likely to have a long vowel preceding gn
First, Allen addresses Priscian, and argues that the passage quoted above, in Keil II.82, is an interpolation first based on context:
The interpolatory nature of the 'gnus' passage is strongly suggested by its irrelevant interruption of the discussion of proper names, more particularly those with adjectives in -īnus; and by introduction of nouns into a chapter which is exclusively concerned with adjectives.
The interpolator, Allen continues, misinterpreted Priscian's discussion of Anagnīnus, where the vowel following gn, not preceding it, is long. Furthermore, the examples of the rule are not convincing: in several we would expect a long vowel for historical/phonological reasons, while many common words, for which we have evidence of a short vowel, are not mentioned. Allen summarizes:
It seems most probable, therefore, that what the interpolator states as a general rule is not so, and that he was at a loss to cite much more by way of example.
Turning to inscriptions, Allen says "we nowhere find even so common a word as magnus marked with a long a." There is some evidence for a long i in a few of the interpolator's examples, but Allen suggests that this could be explained by phonetic influences on the short i before [ŋ] that made its quality (not length) approach that of the long ī. This explanation is corroborated by long ī appearing occassionally in front of other inscriptional instances of [ŋ], like ng, nc and nqu.
Thus, Allen concludes:
We may safely say, then, that the vowel is long in rēgnum, stāgnum, sēgnis, abiēgnus, but probably NOT before gn in any other instances.