Traditionally (and for all I know) the trees weren't farmed. Somebody just walked around until they found a suitable tree and then cut it down. So...hunting and gathering. But IIR, people track the growth of individual trees to make sure they're harvested at the right age, but they aren't specifically planted or cultivated in a "farm" sense.
It's not a terribly different notion from what's being written about here I think. I would guess that humans have found starches of various kinds throughout their environment, extracted and processed them, and then made simple flatbreads or pancakes almost everywhere.
It doesn't even have to be obvious. The line from palm tree to sago is not clear at all. Why even consider eating the core of a tree? Why invent a long, multi-part, labor intensive process to make it more edible? Nobody really knows how it started.
But I think the important point I got from this was that agriculture is not a clean cut-off. You aren't digging out root vegetables one day and then planting wheat the next. There must be some kind of transition period that depends on the local plant life and many of the things that we think of as indicative of post cut-off agriculture societies probably aren't that at all.