They could have done it in 1938-9, but AAF was committed to the V1710 by then.
It is hard sorting out the actual timing. 1938 was too early. The contact in April 1939 for the P-40s was first for more than few dozen engines, (in 1938 a contract for 20 engines for the YP-37 was expanded by 39 engines for the YFM-1 (Airacuda) but contracts took a while. Allison only completed 48 engines in 1939. They completed 1153 in 1940, but here is a kicker, only around 340 of them were for the US, the rest were exported to Britain (both French and British contracts.
The R-1830 with two stage engine existed in 1938 but it needed some work, it is supposed to have flown in both a Seversky and a Curtiss at the 1939 fighter trials. The XP-40 was selected on the grounds that it could be issued to service squadrons sooner (mid 1940 goal). P&W got the P-40 airframe in 1940, what happened to it in 1941-42 seems to be something of a mystery. The really high performance numbers only show up in mid 1943 and later. Curtiss and P&W were working on the XP-42 for more streamlining and went through at least 12 different cowls, nose cones and extension shaft/s. One set up seems to show a fan behind the propeller spinner.
A lot of work went into cowls and cooling and exhaust systems for radial engines between 1939 and 1943.
I would also note that the Army was not committed to the V-1710 in 1939. They were still funding the XI-1430 and the O-1230 with the XI-1430 being the faired hair boy and the Allison engine being the temporary fill in. They ordered V-1710s because they were further along in development and they needed something, anything for equipment in 1940-41 while they waited for the super planes powered by the favored "hyper" engines.
Now part of the underfunding of the Allison was part general underfunding of the defense sector in general. And part was the Army trying to fund a number of programs at the same time. Congress was not helping. The Army forced Allison to forgive 900,000 dollars in 1939 money for permission to export the V-1710 to France and Britain. Money that was owed to Allison/GM for past work. Goes a long way to explain why Allison was NOT developing advanced supercharger set-ups on speculation of getting orders in the future. They were trying to keep from going bankrupt and building the factory space that would allow them to export engines to make a profit on work already done.
to further put some of this in perspective. There were something like 16 different versions of the XXX-1430 engine from flat 12, inverted V and upright V. The Army paid for a new plant for Continental to make the engine (used for R-985 radials (?) and end of the war Merlins) and for all of this sound and fury, they actually powered the XP-49 (1) and the XP-67 (1) and one or more converted test bed aircraft.
The engine was actually designed by army engineers at Wright field, at least it started there, and Continental did the construction/testing as a sort of contractor. Work had started in 1932. The first 12 cylinder version was built in 1938 and tested in 1939 (starting to make the Allison look speedy in development) 23 total engines built and development mercifully ended in 1944 without ever getting a useful engine (never made hoped for power and was plagued with failures and fires).
This was the engine that was supposed to go into offshoots of the P-38 (XP-49), the P-39(like the XP-76) , the P-40 (XP-53/60) and some others to replace the Allison. How much this held back the Allison development I don't know. But the Allison was
competing with an engine that had been designed by USAAC engineers.
That was 100% the fault of VERY little development money or contracts due to the great depression's continuing influence right up until Pearl Harbor more or les forced our hand to enter the war.
The state of development of the Allison V-1710 was almost exactly what got funded from 1929 to 7 Dec 1941.
This overlooks the huge change that occurred in 1940.
FDR Speech of May 16th 1940, excerpt.
During the past year American production capacity for war planes, including engines, has risen from approximately 6,000 planes a year to more than double that number, due in greater part to the placing of foreign orders here.Our immediate problem is to superimpose on this production capacity a greatly increased additional production capacity. I should like to see this nation geared up to the ability to turn out at least 50,000 planes a year. Furthermore, I believe that this nation should plan at this time a program that would provide us with 50,000 military and naval planes.
I don't know what he actually got (actual money, he asked for $896,000,000) but by the end of 1940 Ford, Packard, Buick, Chevrolet and Studebaker all had plants under construction/conversion and expansions at P&W and Wright (in addition to the French/British contracts). It takes time to go from bare plots of ground to large factories making hundreds of engines per month. The Idea that the US did it after Dec 7th 1941 is a myth.
Airframe builders were under going similar expansion.