Looking for mentions of karma related to actions taken while dreaming I am looking for early mentions of the accumulation of karma while dreaming.

Here is what I've been able to find so far:


In The Large Sutra on Perfect Wisdom a discussion of accumulating karma in dreams:


  Sāriputra: Ven. Subhuti, the Bodhisattva, the great being, who in
  his dreams enters into the three concentrations—emptiness, the
  signless, the wishless—does he, then, grow in perfect wisdom?
  
  Subhuti: If, Ven. Śāriputra, he grows through the development by
  day, then he also grows in a dream. And why? Because dream and waking
  are indiscriminate. If the Bodhisattva who courses by day in the
  perfection of wisdom has a development of the perfection of wisdom,
  then also the Bodhisattva, the great being, who dreams will have a
  development of the perfection of wisdom.
  
  Śāriputra: If again, Ven. Subhuti, the Bodhisattva, the great
  being, does a deed in his dream, will there by of that deed a heaping
  up or accumulation? If all dharmas are said to be like a dream, there
  will be no heaping up or accumulation of it. And why? Because in a
  dream no heaping up or accumulation of a dharma can be apprehended.
  But when one wakes up and thinks it over, then there is a heaping up
  or accumu- lation of it.
  
  Subhuti: One who had committed a murder in his dream, and, on
  waking, would think it over like this, 'he has been well killed by me,
  (A: it is right that he was killed, it is just that he was killed, it
  was I who killed him!' Such thoughts are equivalent to the conscious
  notion that he wants to kill someone).
  
  Śāriputra: Not without an objective support does a deed arise or an
  act of will.
  
  Subhuti: So it is, Śāriputra, not without an objective support does
  a deed arise or an act of will. Only with an objective support is a
  deed produced, or an act of will, and not without. In seen, heard, and
  known dharmas does intelligence proceed, and not in unseen, unheard,
  unknown dharmas. Therein some intellectual acts take hold of
  defilement, and some of purification. Therefore, then, Śāriputra, it
  is with an objective support that a deed or act of will arises and not
  without objective support.

In Tsongkhapa's Praise for Dependent Relativity it is mentioned that the karma of killing in a dream was a question answered by the Buddha, but no sources are provided.
Shantideva addressed this (or a closely related) question in Chapter 9 of his Guide to the Bodhisattvas Way of Life verse 11 and on:


  If consciousness does not exist, there is no sin in killing an
  illusory person. On the contrary, when one is endowed with the
  illusion of consciousness, vice and merit do arise.

In the Perfection of Wisdom in 8000 lines:


  Sariputra: If someone in his dreams does a deed, wholesome or
  unwholesome, will that be added on to the heap or collection of his
  karma?
  
  Subhuti: In so far as the Lord has taught that ultimately all dharmas
  are like a dream, in so far that deed will not be added to his head or
  collection of karma. But on the other hand [from the standpoint of
  empirical reality], that deed will be added to the heap and collection
  of his karma if, after the man has woken up, he thinks the dream over,
  and consciously forms the notion that he wants to kill someone. How
  does he do that? During his dream he may have taken life, and after he
  has woken up, he thinks it over like this: “it is good that he was
  killed! It is right that he was killed! It was just that he was
  killed! It was I who killed him.” Such thoughts are equivalent to the
  conscious notion that he wants to kill someone.



Does anyone know of sutras or other ancient sources where the Buddha or Nagarjuna, Shantideva, Chandrakirti, Aryadeva, Buddhapalita, Tsongkhapa or others might have addressed the question of whether karma can be accumulated in dreams and if so, how?

I'm especially interested to know if this question was ever answered or addressed by the Buddha in the pali canon
I think it's listed as a point of controversy in the Abhidhamma -- Kv 22.6:

Controverted Point: That all dream-consciousness is ethically neutral.
22.6.1 Theravādin: You admit, do you not, that a dreamer may (in dreams) commit murder, theft, etc.? How then can you call such consciousness ethically neutral?
22.6.2 Uttarapāthakas: If I am wrong, was it not said by the Exalted One that dream-consciousness was negligible? If so, my proposition holds good.

I think the (Theravādin) argument is that intention (e.g. intention to murder) may be present, therefore it's not ethically neutral.
I think the counter-argument is that there's no material result, so if it's not neutral it's negligible.
See also the Vinaya -- that defines offences (e.g. killing) in some detail or legalistically (i.e. in more detail than the suttas do) -- and there, there are various (several) conditions which must be met for the offence of e.g. &quot;killing&quot; to have occurred, one of which is that somebody has to die -- and in a dream, nobody is really killed, so that wouldn't be counted (and punished) as the offence of killing.
The Abhidhamma is considered part of the Pali canon, even if it isn't all quotes from the Buddha.
In Tsongkhapa's Praise for Dependent Relativity it is mentioned that the karma of killing in a dream was a question answered by the Buddha, but no sources are provided.
So far as I known, the commentary to the Vinaya pronounces the non-punishment of sexual actions performed while dreaming (while also saying it's better not to).
It's not exacty right to equate the working of kamma with the rules of the Vinaya, however that may be the best we have -- because the Vinaya is defined in detail whereas the suttas don't describe kamma in every detail -- even say that the precise workings of kamma is known to the Buddha but is unconjecturable -- and, the Vinaya was defined by the Buddha.