Well, I put this off long enough, but it's about time I answer it
Note: I didn't do PLA Pokemon, as I haven't played that game yet and don't want to spoil myself. I also categorized the Pokemon by dex order so the list is much more convenient.
Pokemon without a label in Gen 1-4 can learn those moves in both BDSP and Sw/Sh, or if they're unavailable in one game, and available in another (such as Castform being in BDSP, but not Sw/Sh). Ones labeled "In BDSP" or "In SW/SH" can only learn those moves in that game. The US/UM movesets are only used by a Pokemon if they first appeared in Generations 5-7, and unavailable in Sw/Sh. Sorry if this is super confusing, this is just how it makes sense to me.
Now updated to include Generation 9 Pokemon
Generation 1:
Bulbasaur learns Poison Powder and Sleep Powder at level 15
Ivysaur learns Poison Powder and Sleep Powder at level 15
Venusaur learns Poison Powder and Sleep Powder at level 15
Butterfree learns Poison Powder, Sleep Powder, and Stun Spore at level 12
Ekans learns Spit Up, Stockpile, and Swallow at level 25 in BDSP
Arbok learns Spit Up, Stockpile, and Swallow at level 27 in BDSP
Jigglypuff learns Spit Up, Stockpile, and Swallow at level 12
Paras learns Poison Powder and Sleep Powder at level 6 in BDSP
Parasect learns Poison Powder and Sleep Powder at level 6 in BDSP
Hitmonchan learns Fire Punch, Ice Punch, and Thunder Punch at level 24
Mr. Mime learns Light Screen, Reflect, and Safeguard at level 36
Snorlax learns Rest, Sleep Talk, and Snore at level 20
Mewtwo learns Guard Swap and Power Swap at level 56
Generation 2:
Ledyba learns Light Screen, Reflect, and Safeguard at level 12 in BDSP
Ledian learns Light Screen, Reflect, and Safeguard at level 12 in BDSP
Natu learns Guard Swap and Psychic at level 35
Xatu learns Guard Swap and Power Swap at level 34
Wooper learns Haze and Mist at level 12
Quagsire learns Haze and Mist at level 12
Qwilfish learns Spit Up and Stockpile at level 44
Shuckle learns Guard Split and Power Split at level 35
Teddiursa learns Rest and Snore at level 43
Hitmontop learns Quick Guard and Wide Guard at level 21
Generation 3:
Pelipper learns Spit Up, Stockpile, and Swallow at level 28
Surskit learns Haze and Mist at level 25
Masquerain learns Air Cutter and Scary Face at level 22
Whismur learns Rest and Sleep Talk at level 15
Loudred learns Rest and Sleep Talk at level 15
Exploud learns Rest and Sleep Talk at level 15
Mawile learns Spit Up, Stockpile, and Swallow at level 16
Gulpin learns Spit Up, Stockpile, and Swallow at level 28
Swalot learns Spit Up, Stockpile, and Swallow at level 30
Camerupt learns Ember and Focus Energy at level 8
Spoink learns Power Gem and Rest at level 29
Grumpig learns Rest and Snore at level 35
Barboach learns Rest and Snore at level 6
Baltoy learns Guard Split and Power Split at level 36
Claydol learns Guard Split and Power Split at level 38
Lileep learns Spit Up, Stockpile, and Swallow at level 41
Cradily learns Spit Up, Stockpile, and Swallow at level 43
Castform learns Ember, Powder Snow, and Water Gun at level 10 in BDSP
Castform learns Hail, Rain Dance, and Sunny Day at level 20 in BDSP
Castform learns Blizzard, Fire Blast, and Hydro Pump at level 35 in BDSP
Registeel learns Amnesia and Iron Defense at level 36
Generation 4:
Vespiquen learns Attack Order and Defend Order at level 40
Drifloon learns Spit Up, Stockpile, and Swallow at level 24
Drifblim learns Spit Up, Stockpile, and Swallow at level 24
Mime Jr. learns Light Screen, Reflect, and Safeguard at level 36
Munchlax learns Stockpile and Swallow at level 20
Carnivine learns Spit Up, Stockpile, and Swallow at level 37
Gallade learns Quick Guard and Wide Guard at level 56
Probopass learns Lock-On and Zap Cannon at level 43
Generation 5:
Sigilyph learns Light Screen and Reflect at level 30
Yamask learns Guard Split and Power Split at level 48
Galarian Yamask learns Guard Split and Power Split at level 48
Cofagrigus learns Guard Split and Power Split at level 56
Trubbish learns Stockpile and Swallow at level 21
Garbodor learns Stockpile and Swallow at level 21
Solosis learns Light Screen and Reflect at level 24
Duosion learns Light Screen and Reflect at level 24
Reuniclus learns Light Screen and Reflect at level 24
Elgyem learns Guard Split and Power Split at level 24
Beheeyem learns Guard Split and Power Split at level 24
Cryogonal learns Haze and Mist at level 20
Cryogonal learns Night Slash and Slash at level 32
Cryogonal learns Light Screen and Reflect at level 40
Heatmor learns Spit Up, Stockpile, and Swallow at level 20
Generation 6:
Espurr learns Light Screen and Reflect at level 30
Male & Female Meowstic learn Light Screen and Reflect at level 34
Dedenne learns Rest and Snore at level 35
Pumpkaboo learns Razor Leaf and Trick-or-Treat at level 12
Pumpkaboo learns Scary Face and Trick-or-Treat at level 24
Pumpkaboo learns Shadow Ball and Trick-or-Treat at level 36 (Why does this thing learn Trick-or-Treat three times?)
Gourgeist learns Razor Leaf and Trick-or-Treat at level 12
Gourgeist learns Scary Face and Trick-or-Treat at level 24
Gourgeist learns Shadow Ball and Trick-or-Treat at level 36
Hoopa learns Guard Split and Power Split at level 29
Hoopa learns Trick Room and Wonder Room at level 50
Volcanion learns Haze and Mist at level 60
Generation 7:
Komala learns Spit Up, Stockpile, and Swallow at level 6
Tapu Fini learns Haze and Mist at level 10
Nihilego learns Guard Split and Power Split at level 25
Generation 8:
Skwovet learns Spit Up, Stockpile, and Swallow at level 15
Greedent learns Spit Up, Stockpile, and Swallow at level 15
Runerigus learns Guard Split and Power Split at level 56
Generation 9:
Skeledirge learns Hex and Will-o-Wisp at level 47
Shroodle learns Bite and Fury Swipes at level 8
Toedscool learns Poison Powder and Stun Spore at level 8
Toedscruel learns Poison Powder and Stun Spore at level 8
Scovillain learns Overheat and Solar Beam at level 48
Rabsca learns Guard Swap, Power Swap, and Speed Swap at level 40
Wiglett learns Slam and Water Pulse at level 20
Greavard learns Bite and Tail Whip at level 6
Houndstone learns Bite and Tail Whip at level 6
Dondozo learns Rest and Sleep Talk at level 15
Slither Wing learns Poison Powder and Stun Spore at level 7
Wo-Chien learns Poison Powder and Stun spore at level 15
Chien-Pao learns Haze and Mist at level 15
Iron Valiant learns Quick Guard and Wide Guard at level 84
And that's all of them! I may have missed a couple, so please tell me if I have
Source: The site you're currently on, and a typical person with too much free time